summaryrefslogtreecommitdiff
path: root/output.h
diff options
context:
space:
mode:
authorPaul Smith <psmith@gnu.org>2013-09-21 17:24:59 -0400
committerPaul Smith <psmith@gnu.org>2013-09-21 17:24:59 -0400
commitecd4942fd48b12ba667440a6605fe3436b74bf46 (patch)
tree2f5d702aa25de4f1815eed3f57b8b43cbf0dca35 /output.h
parent37a11621cc6b093e9500efa8f374390c800a2d50 (diff)
downloadmake-ecd4942fd48b12ba667440a6605fe3436b74bf46.tar.gz
Ensure that output generated while reading makefiles is synced.
Diffstat (limited to 'output.h')
-rw-r--r--output.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/output.h b/output.h
index 1f0e2d7c..5fef436c 100644
--- a/output.h
+++ b/output.h
@@ -24,7 +24,7 @@ struct output
extern struct output *output_context;
extern unsigned int stdio_traced;
-#define OUTPUT_SET(_new) do{ if ((_new)->syncout) output_context = (_new); }while(0)
+#define OUTPUT_SET(_new) do{ output_context = (_new)->syncout ? (_new) : NULL; }while(0)
#define OUTPUT_UNSET() do{ output_context = NULL; }while(0)
#define OUTPUT_TRACED() do{ stdio_traced = 1; }while(0)