From c22c06adbe2351bcfbbd60326fc3b600206e701e Mon Sep 17 00:00:00 2001 From: Maxim Biro Date: Fri, 1 Jan 2016 02:46:14 -0500 Subject: Flush stdout output Apparently when no tty is attached, which is the case for Docker, the buffer size for stdout increases to the point that only half of the entire log might be written. --- other/bootstrap_daemon/src/log.c | 1 + 1 file changed, 1 insertion(+) (limited to 'other/bootstrap_daemon/src') diff --git a/other/bootstrap_daemon/src/log.c b/other/bootstrap_daemon/src/log.c index b3aec180..d441b98e 100644 --- a/other/bootstrap_daemon/src/log.c +++ b/other/bootstrap_daemon/src/log.c @@ -94,6 +94,7 @@ FILE* level_stdout(LOG_LEVEL level) void log_stdout(LOG_LEVEL level, const char *format, va_list args) { vfprintf(level_stdout(level), format, args); + fflush(level_stdout(level)); } bool write_log(LOG_LEVEL level, const char *format, ...) -- cgit v1.2.3