summaryrefslogtreecommitdiffstats
path: root/MultiMC.cpp
diff options
context:
space:
mode:
authorrobotbrain <robotbrainify@gmail.com>2014-03-05 16:27:18 -0500
committerrobotbrain <robotbrainify@gmail.com>2014-03-05 16:27:18 -0500
commitbb6894893d3da021ea0f2e30615fe9ed72502e5b (patch)
treed84cf7c6a575a2b333f68ae6f8fcf791492111fd /MultiMC.cpp
parent97ad7d287c8d99aae6e5f030e1d5669b36ee254b (diff)
downloadMultiMC-bb6894893d3da021ea0f2e30615fe9ed72502e5b.tar
MultiMC-bb6894893d3da021ea0f2e30615fe9ed72502e5b.tar.gz
MultiMC-bb6894893d3da021ea0f2e30615fe9ed72502e5b.tar.lz
MultiMC-bb6894893d3da021ea0f2e30615fe9ed72502e5b.tar.xz
MultiMC-bb6894893d3da021ea0f2e30615fe9ed72502e5b.zip
Fix it - it did it even if the op failed.
Diffstat (limited to 'MultiMC.cpp')
-rw-r--r--MultiMC.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/MultiMC.cpp b/MultiMC.cpp
index 51fd84ac..ff4b186a 100644
--- a/MultiMC.cpp
+++ b/MultiMC.cpp
@@ -1,4 +1,3 @@
-
#include "MultiMC.h"
#include <iostream>
#include <QDir>
@@ -324,11 +323,15 @@ void MultiMC::initGlobalSettings()
QString ftbDefault = QDir::home().absoluteFilePath(".ftblauncher");
#elif defined(Q_OS_WIN32)
wchar_t buf[1000];
+ QString ftbDefault;
if(!GetEnvironmentVariableW(L"APPDATA", buf, 1000))
{
- QLOG_FATAL() << "Your APPDATA folder is missing! If you are on windows, this means your system is corrupt. If you aren't on windows, you have a problem.";
+ QLOG_FATAL() << "Your APPDATA folder is missing! If you are on windows, this means your system is broken. If you aren't on windows, how the **** are you running the windows build????";
+ }
+ else
+ {
+ ftbDefault = PathCombine(QString::fromWCharArray(buf), "ftblauncher");
}
- QString ftbDefault = PathCombine(QString::fromWCharArray(buf), "ftblauncher");
#elif defined(Q_OS_MAC)
QString ftbDefault =
PathCombine(QDir::homePath(), "Library/Application Support/ftblauncher");