Codefix: don't send desync=0 log messages to commands.log (#12517)

They are only used during replay, and you want to see those in
the console; not in the log.
This commit is contained in:
Patric Stout 2024-04-17 21:51:36 +02:00 committed by GitHub
parent 1005c86c62
commit a09749f6a6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -110,7 +110,7 @@ void DumpDebugFacilityNames(std::back_insert_iterator<std::string> &output_itera
*/
void DebugPrint(const char *category, int level, const std::string &message)
{
if (strcmp(category, "desync") == 0) {
if (strcmp(category, "desync") == 0 && level != 0) {
static FILE *f = FioFOpenFile("commands-out.log", "wb", AUTOSAVE_DIR);
if (f == nullptr) return;