Skip to content

Commit

Permalink
Merge pull request #499 from vlohacks/main
Browse files Browse the repository at this point in the history
fix path creation in gamesave.cpp
  • Loading branch information
Lgt2x authored Jul 22, 2024
2 parents 7cd7902 + 07a99c3 commit d3659bb
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Descent3/gamesave.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -399,8 +399,10 @@ void SaveGameDialog() {
// create savegame directory if it didn't exist before.
std::error_code ec;
if (!std::filesystem::create_directories(savegame_dir, ec)) {
DoMessageBox(TXT_ERROR, TXT_ERRCREATEDIR, MSGBOX_OK);
return;
if (ec) {
DoMessageBox(TXT_ERROR, TXT_ERRCREATEDIR, MSGBOX_OK);
return;
}
}

// open window
Expand Down

0 comments on commit d3659bb

Please sign in to comment.