Skip to content

Commit

Permalink
Merge pull request #739 from simons-public/gui-status-log-comments
Browse files Browse the repository at this point in the history
GUI status log comments
  • Loading branch information
p12tic committed Jun 6, 2020
2 parents 69cfd14 + 7331519 commit c336cfd
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/lib/barrier/ClientApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,8 @@ ClientApp::scheduleClientRestart(double retryTime)
void
ClientApp::handleClientConnected(const Event&, void*)
{
// using CLOG_PRINT here allows the GUI to see that the client is connected
// regardless of which log level is set
LOG((CLOG_PRINT "connected to server"));
resetRestartTimeout();
updateStatus();
Expand Down
3 changes: 3 additions & 0 deletions src/lib/barrier/ServerApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -555,6 +555,9 @@ ServerApp::startServer()
m_server->setListener(listener);
m_listener = listener;
updateStatus();

// using CLOG_PRINT here allows the GUI to see that the server is started
// regardless of which log level is set
LOG((CLOG_PRINT "started server (%s), waiting for clients", family));
m_serverState = kStarted;
return true;
Expand Down
3 changes: 3 additions & 0 deletions src/lib/barrier/win32/DaemonApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -353,6 +353,9 @@ DaemonApp::handleIpcMessage(const Event& e, void*)
LOG((CLOG_DEBUG "ipc hello, type=%s", type.c_str()));

const char * serverstatus = m_watchdog->isProcessActive() ? "active" : "not active";

// using CLOG_PRINT here allows the GUI to see that the server status
// regardless of which log level is set
LOG((CLOG_PRINT "server status: %s", serverstatus));

m_ipcLogOutputter->notifyBuffer();
Expand Down

0 comments on commit c336cfd

Please sign in to comment.