Debug: Extend random debug logging to also include state checksum updates
This commit is contained in:
@@ -52,6 +52,7 @@ int _debug_linkgraph_level;
|
||||
int _debug_sound_level;
|
||||
#ifdef RANDOM_DEBUG
|
||||
int _debug_random_level;
|
||||
int _debug_statecsum_level;
|
||||
#endif
|
||||
|
||||
const char *_savegame_DBGL_data = nullptr;
|
||||
@@ -88,6 +89,7 @@ struct DebugLevel {
|
||||
DEBUG_LEVEL(sound),
|
||||
#ifdef RANDOM_DEBUG
|
||||
DEBUG_LEVEL(random),
|
||||
DEBUG_LEVEL(statecsum),
|
||||
#endif
|
||||
};
|
||||
#undef DEBUG_LEVEL
|
||||
@@ -140,7 +142,7 @@ static void debug_print(const char *dbg, const char *buf)
|
||||
fflush(f);
|
||||
}
|
||||
#ifdef RANDOM_DEBUG
|
||||
} else if (strcmp(dbg, "random") == 0) {
|
||||
} else if (strcmp(dbg, "random") == 0 || strcmp(dbg, "statecsum") == 0) {
|
||||
#if defined(UNIX) && defined(__GLIBC__)
|
||||
static bool have_inited = false;
|
||||
static FILE *f = nullptr;
|
||||
|
||||
Reference in New Issue
Block a user