diff options
Diffstat (limited to 'src/util/debug.c')
-rw-r--r-- | src/util/debug.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/util/debug.c b/src/util/debug.c index d26d31c9..5b6fccd6 100644 --- a/src/util/debug.c +++ b/src/util/debug.c @@ -152,3 +152,16 @@ int open_debug_file(void) { return open_debug_file_ex(NULL, NULL); } + +int rotate_debug_files(void) +{ + int ret; + + if (!debug_to_file) return EOK; + + ret = fclose(debug_file); + if (ret) return ret; + debug_file = NULL; + + return open_debug_file(); +} |