Skip to content

Commit

Permalink
QT: Use SetStatusText instead of passing a formatted string as a fmt
Browse files Browse the repository at this point in the history
This caused crashes when file names had percent signs in them because we passed the file name as the format to SetFormattedStatusText. I opted to continue to use fmt for consistency.
  • Loading branch information
F0bes committed Nov 23, 2024
1 parent f113a51 commit e3fedf1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pcsx2/GameList.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,7 @@ void GameList::ScanDirectory(const char* path, bool recursive, bool only_cache,
}

const std::string_view filename = Path::GetFileName(ffd.FileName);
progress->SetFormattedStatusText(fmt::format(TRANSLATE_FS("GameList","Scanning {}..."), filename.data()).c_str());
progress->SetStatusText(fmt::format(TRANSLATE_FS("GameList","Scanning {}..."), filename.data()).c_str());
ScanFile(std::move(ffd.FileName), ffd.ModificationTime, lock, played_time_map, custom_attributes_ini);
progress->SetProgressValue(files_scanned);
}
Expand Down

0 comments on commit e3fedf1

Please sign in to comment.