isleapp: Use binary mode for iniFP

Windows treats newlines differently then on *nix systems. Using binary mode makes this consistent.

Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>
This commit is contained in:
AllMeatball 2025-05-12 17:25:35 +00:00 committed by GitHub
parent eb7ae0a5f5
commit 6bb7a61908
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -549,7 +549,7 @@ void IsleApp::LoadConfig()
// Load sane defaults if dictionary failed to load
if (!dict) {
SDL_LogInfo(SDL_LOG_CATEGORY_APPLICATION, "Loading sane defaults");
FILE* iniFP = fopen(iniConfig, "w");
FILE* iniFP = fopen(iniConfig, "wb");
if (!iniFP) {
SDL_LogError(SDL_LOG_CATEGORY_APPLICATION, "Failed to write config at '%s': %s", iniConfig, strerror(errno));