diff --git a/gui/src/AppConfig.cpp b/gui/src/AppConfig.cpp index 2ef35e0b..543bc633 100644 --- a/gui/src/AppConfig.cpp +++ b/gui/src/AppConfig.cpp @@ -83,7 +83,7 @@ void AppConfig::loadSettings() m_Interface = settings().value("interface").toString(); m_LogLevel = settings().value("logLevel", 2).toInt(); m_AutoDetectPaths = settings().value("autoDetectPaths", true).toBool(); - m_LogToFile = settings().value("logToFile", true).toBool(); + m_LogToFile = settings().value("logToFile", false).toBool(); m_LogFilename = settings().value("logFilename", synergyLogDir() + "synergy.log").toString(); } diff --git a/lib/arch/CArchAppUtilWindows.cpp b/lib/arch/CArchAppUtilWindows.cpp index 0a957e56..1480c505 100644 --- a/lib/arch/CArchAppUtilWindows.cpp +++ b/lib/arch/CArchAppUtilWindows.cpp @@ -118,7 +118,12 @@ CArchAppUtilWindows::getServiceArgs() const i++; } else { - argBuf << " " << __argv[i]; + if (strchr(arg, ' ') != NULL) { + // surround argument with quotes if it contains a space + argBuf << " \"" << arg << "\""; + } else { + argBuf << " " << arg; + } } } return argBuf.str();