Don't punch me in the face, and also fix the compilation, and also fix a stupid bug in log replay.

This commit is contained in:
starfrost013
2025-01-12 19:07:27 +00:00
parent 6eaec5b756
commit 55f476617d
3 changed files with 11 additions and 12 deletions

View File

@@ -271,8 +271,7 @@ static int suppr_seen = 1;
/*
Ensures STDLOG is open for pclog_ex and pclog_ex_cyclic
*/
void
pclog_ensure_stdlog_open()
void pclog_ensure_stdlog_open()
{
if (stdlog == NULL) {
if (log_path[0] != '\0') {
@@ -399,7 +398,7 @@ pclog_ex_cyclic(const char* fmt, va_list ap)
{
// *very important* to prevent out of bounds index
uint32_t real_index = index % LOG_SIZE_BUFFER_CYCLIC_LINES;
fprintf(stdlog, "%s", temp);
fprintf(stdlog, "%s", cyclic_buff[real_index]);
}