From e928d8baf2d3ac48141eaddb522aef6361542971 Mon Sep 17 00:00:00 2001 From: Koichiro IWAO Date: Tue, 7 Jan 2020 19:24:17 +0900 Subject: [PATCH] common: flush stream in g_deinit() unless flushing stream before exitting, `xrdp --version | cat` will show empty output. Fixes #1471. --- common/os_calls.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/common/os_calls.c b/common/os_calls.c index 2b4e0e9b..54b2c3ed 100644 --- a/common/os_calls.c +++ b/common/os_calls.c @@ -166,6 +166,8 @@ g_deinit(void) #if defined(_WIN32) WSACleanup(); #endif + fflush(stdout); + fflush(stderr); g_rm_temp_dir(); }