From 0ebe69dc67853e9e2b2b7b22069e766a7cbc057d Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 24 Mar 2016 16:19:47 +0100 Subject: [PATCH] Re-enable sync_with_stdio Otherwise writing to std::cerr is not thread-safe (in particular, lines will be randomly duplicated). --- src/libmain/shared.cc | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/libmain/shared.cc b/src/libmain/shared.cc index e883967b7..e26483211 100644 --- a/src/libmain/shared.cc +++ b/src/libmain/shared.cc @@ -117,9 +117,6 @@ void initNix() std::cerr.rdbuf()->pubsetbuf(buf, sizeof(buf)); #endif - // FIXME: do we need this? It's not thread-safe. - std::ios::sync_with_stdio(false); - if (getEnv("IN_SYSTEMD") == "1") logType = ltSystemd;