mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2025-02-16 23:30:15 -05:00
Fix save corruption on switch (#1585)
This commit is contained in:
parent
e412a8b55e
commit
da893a5b86
@ -523,9 +523,9 @@ void SaveManager::SaveFile(int fileNum) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifdef __SWITCH__
|
#ifdef __SWITCH__
|
||||||
const char* json_string = baseBlock.dump(4).c_str();
|
|
||||||
FILE* w = fopen(GetFileName(fileNum).c_str(), "w");
|
FILE* w = fopen(GetFileName(fileNum).c_str(), "w");
|
||||||
fwrite(json_string, sizeof(char), strlen(json_string), w);
|
std::string json_string = baseBlock.dump(4);
|
||||||
|
fwrite(json_string.c_str(), sizeof(char), json_string.length(), w);
|
||||||
fclose(w);
|
fclose(w);
|
||||||
#else
|
#else
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user