fix: Use Mode::Create instead of Mode::Write when creating crash file (#1134)

This commit is contained in:
iTrooz 2023-06-11 13:10:04 +02:00 committed by GitHub
parent f0be585fd8
commit cac9a69ea2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -39,7 +39,7 @@ namespace hex::crash {
}; };
for (const auto &path : fs::getDefaultPaths(fs::ImHexPath::Config)) { for (const auto &path : fs::getDefaultPaths(fs::ImHexPath::Config)) {
wolv::io::File file(path / "crash.json", wolv::io::File::Mode::Write); wolv::io::File file(path / "crash.json", wolv::io::File::Mode::Create);
if (file.isValid()) { if (file.isValid()) {
file.writeString(crashData.dump(4)); file.writeString(crashData.dump(4));
file.close(); file.close();