Flush stdout after trace messages

This immediately shows log messages when stdout is not connected to a
tty.
This commit is contained in:
Daniel Nagy 2021-08-15 22:56:36 +02:00
parent 4eb3d8857f
commit 1965df3d91
No known key found for this signature in database
GPG Key ID: 1B8E8DCB576FB671

View File

@ -148,6 +148,7 @@ void TraceLog(int logType, const char *text, ...)
strcat(buffer, text); strcat(buffer, text);
strcat(buffer, "\n"); strcat(buffer, "\n");
vprintf(buffer, args); vprintf(buffer, args);
fflush(stdout);
#endif #endif
va_end(args); va_end(args);