X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/0f359e5ccf10506edb4f0f98468db962a8e4fd79..8076df5d81549d5afe7afe392e3b531964e33d47:/samples/sockets/baseserver.cpp diff --git a/samples/sockets/baseserver.cpp b/samples/sockets/baseserver.cpp index c74ef28666..ae30bce692 100644 --- a/samples/sockets/baseserver.cpp +++ b/samples/sockets/baseserver.cpp @@ -101,7 +101,7 @@ WX_DECLARE_LIST(EventWorker, EList); //and list of two type worker classes that serve clients class Server : public wxApp { - DECLARE_EVENT_TABLE(); + DECLARE_EVENT_TABLE() public: Server() : m_maxConnections(-1) {} ~Server() {} @@ -198,7 +198,7 @@ private: void DoWrite(); void DoRead(); - DECLARE_EVENT_TABLE(); + DECLARE_EVENT_TABLE() }; /******************* Implementation ******************/ @@ -688,17 +688,17 @@ void EventWorker::OnSocketEvent(wxSocketEvent& pEvent) break; case wxSOCKET_OUTPUT: - if (m_inbuf != NULL) + if ( m_outbuf ) DoWrite(); break; case wxSOCKET_CONNECTION: - LogWorker(wxString::Format("Unexpected wxSOCKET_CONNECTION in EventWorker"),wxLOG_Error); + LogWorker("Unexpected wxSOCKET_CONNECTION in EventWorker", wxLOG_Error); break; case wxSOCKET_LOST: { - LogWorker(wxString::Format("Connection lost")); + LogWorker("Connection lost"); WorkerEvent e(this); e.m_workerFailed = m_written != m_size; wxGetApp().AddPendingEvent(e);