From 0aba1d3e54da35192a94eb51bf18ea1b7054726d Mon Sep 17 00:00:00 2001 From: Ryan Huffman Date: Mon, 26 Sep 2016 09:07:45 -0700 Subject: [PATCH] Fix server arguments causing crash on startup --- interface/src/main.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/interface/src/main.cpp b/interface/src/main.cpp index 7980d3de0f..8dd4414c6b 100644 --- a/interface/src/main.cpp +++ b/interface/src/main.cpp @@ -123,18 +123,18 @@ int main(int argc, const char* argv[]) { } QCommandLineParser parser; - QCommandLineOption runServer("runServer", "Whether to run the server"); - QCommandLineOption serverContentPath("serverContentPath", "Where to find server content", "serverContentPath"); - parser.addOption(runServer); - parser.addOption(serverContentPath); + QCommandLineOption runServerOption("runServer", "Whether to run the server"); + QCommandLineOption serverContentPathOption("serverContentPath", "Where to find server content", "serverContentPath"); + parser.addOption(runServerOption); + parser.addOption(serverContentPathOption); parser.parse(arguments); - if (parser.isSet(runServer)) { + if (parser.isSet(runServerOption)) { QString serverPath = QFileInfo(arguments[0]).path(); serverPath += "/server-console/server-console.exe"; //serverPath = "./server-console/server-console.exe"; QStringList args; - if (parser.isSet(serverContentPath)) { - QString serverContentPath = QFileInfo(arguments[0]).path() + "/" + parser.value(serverContentPath); + if (parser.isSet(serverContentPathOption)) { + QString serverContentPath = QFileInfo(arguments[0]).path() + "/" + parser.value(serverContentPathOption); args << "--" << "--contentPath" << serverContentPath; } qDebug() << "server path: " << serverPath << args;