diff --git a/assignment-client/src/AssignmentClient.cpp b/assignment-client/src/AssignmentClient.cpp index 813062bd6f..ac0ab887d7 100644 --- a/assignment-client/src/AssignmentClient.cpp +++ b/assignment-client/src/AssignmentClient.cpp @@ -37,6 +37,17 @@ AssignmentClient::AssignmentClient(int &argc, char **argv) : QCoreApplication(argc, argv), _assignmentServerHostname(DEFAULT_ASSIGNMENT_SERVER_HOSTNAME) { + +#ifdef Q_OS_WIN + // Windows applications buffer stdout/err hard when not run from a terminal, + // making assignment clients run from the Stack Manager application not flush + // log messages. + // This will disable the buffering. If this becomes a performance issue, + // an alternative is to call fflush(...) periodically. + setbuf(stdout, NULL); + setbuf(stderr, NULL); +#endif + setOrganizationName("High Fidelity"); setOrganizationDomain("highfidelity.io"); setApplicationName("assignment-client"); diff --git a/domain-server/src/DomainServer.cpp b/domain-server/src/DomainServer.cpp index ddef6e7ab1..dcc16edb09 100644 --- a/domain-server/src/DomainServer.cpp +++ b/domain-server/src/DomainServer.cpp @@ -43,6 +43,17 @@ DomainServer::DomainServer(int argc, char* argv[]) : _networkReplyUUIDMap(), _sessionAuthenticationHash() { + +#ifdef Q_OS_WIN + // Windows applications buffer stdout/err hard when not run from a terminal, + // making a domain server run from the Stack Manager application not flush + // log messages. + // This will disable the buffering. If this becomes a performance issue, + // an alternative is to call fflush(...) periodically. + setbuf(stdout, NULL); + setbuf(stderr, NULL); +#endif + setOrganizationName("High Fidelity"); setOrganizationDomain("highfidelity.io"); setApplicationName("domain-server");