Skip to content

Commit

Permalink
Reformat
Browse files Browse the repository at this point in the history
  • Loading branch information
yvt committed Jun 19, 2022
1 parent e658d0b commit d628dd1
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions Sources/Gui/Main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -407,8 +407,7 @@ int main(int argc, char **argv) {
}
}

spades::g_userResourceDirectory = GetSDLPrefPath("OpenSpades");
spades::g_userResourceDirectory += "Resources";
spades::g_userResourceDirectory = GetSDLPrefPath("OpenSpades") + "Resources";

spades::FileManager::AddFileSystem(
new spades::DirectoryFileSystem(spades::g_userResourceDirectory, true));
Expand All @@ -426,13 +425,13 @@ int main(int argc, char **argv) {
SPLog("XDG_DATA_HOME not defined. Assuming that XDG_DATA_HOME is ~/.local/share");
} else {
xdg_data_home = getenv("XDG_DATA_HOME");
xdg_data_home += "/openspades";
xdg_data_home += "/openspades";
SPLog("XDG_DATA_HOME is %s", xdg_data_home.c_str());
}

struct stat info;

if (stat((xdg_data_home).c_str(), &info) != 0) {
if (stat(xdg_data_home.c_str(), &info) != 0) {
if (stat((home + "/.openspades").c_str(), &info) != 0) {
} else if (info.st_mode & S_IFDIR) {
SPLog("Openspades directory in XDG_DATA_HOME not found, though old directory "
Expand Down

0 comments on commit d628dd1

Please sign in to comment.