fix minor cmake issue

This commit is contained in:
Eduardo Bart 2012-06-22 13:02:16 -03:00
parent 170236f822
commit 0c14a8e602
2 changed files with 4 additions and 8 deletions

View File

@ -113,10 +113,6 @@ IF(WIN32)
# fix boost thread linkage
ADD_DEFINITIONS(-DBOOST_THREAD_USE_LIB)
SET(framework_SOURCES ${framework_SOURCES}
${CMAKE_CURRENT_LIST_DIR}/platform/win32window.cpp
${CMAKE_CURRENT_LIST_DIR}/platform/win32crashhandler.cpp)
IF(WINDOWS_CONSOLE)
MESSAGE(STATUS "Windows console: ON")
ELSE()
@ -126,11 +122,7 @@ IF(WIN32)
ELSE()
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pthread")
SET(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} -rdynamic")
SET(ADDITIONAL_LIBRARIES X11 dl)
SET(framework_SOURCES ${framework_SOURCES}
${CMAKE_CURRENT_LIST_DIR}/platform/x11window.cpp
${CMAKE_CURRENT_LIST_DIR}/platform/unixcrashhandler.cpp)
ENDIF()

View File

@ -32,6 +32,7 @@ Protocol::Protocol()
Protocol::~Protocol()
{
assert(!g_app.isTermianted());
disconnect();
}
@ -80,6 +81,9 @@ void Protocol::send(const OutputMessagePtr& outputMessage)
// send
if(m_connection)
m_connection->write(outputMessage->getHeaderBuffer(), outputMessage->getMessageSize());
// reset message to allow reuse
outputMessage->reset();
}
void Protocol::recv()