From 6bb7a619081c3311d8f5d34a38ed3699d2396a6e Mon Sep 17 00:00:00 2001 From: AllMeatball <181806857+AllMeatball@users.noreply.github.com> Date: Mon, 12 May 2025 17:25:35 +0000 Subject: [PATCH] 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 --- ISLE/isleapp.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ISLE/isleapp.cpp b/ISLE/isleapp.cpp index ad402de8..a319646b 100644 --- a/ISLE/isleapp.cpp +++ b/ISLE/isleapp.cpp @@ -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));