1
0
Fork 0
mirror of https://github.com/k4zmu2a/SpaceCadetPinball.git synced 2025-09-01 06:20:15 +02:00

Fix null pointer dereferencing in SDL_GetPrefPath(3)

This commit is contained in:
WHR 2022-11-10 10:36:27 +08:00
parent 3c6e1c9d47
commit fb28e7dab1

View file

@ -109,7 +109,7 @@ int winmain::WinMain(LPCSTR lpCmdLine)
ImGuiIO& io = ImGui::GetIO();
ImIO = &io;
auto prefPath = SDL_GetPrefPath(nullptr, "SpaceCadetPinball");
auto prefPath = SDL_GetPrefPath("", "SpaceCadetPinball");
auto iniPath = std::string(prefPath) + "imgui_pb.ini";
io.IniFilename = iniPath.c_str();