diff options
author | Pat Gavlin <pgavlin@gmail.com> | 2016-06-20 10:25:07 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-06-20 10:25:07 -0700 |
commit | ee680783778ed0abb186ae41a8c861d5cdcadccd (patch) | |
tree | 18853a0c856374fcdae7e9aa4dc8118c1333c6d7 | |
parent | 79ae4d44b7dc71f098ab97e712f8af7c493e720f (diff) | |
parent | bc3533fb742458bd6939f7f878bf8f477cbac791 (diff) | |
download | coreclr-ee680783778ed0abb186ae41a8c861d5cdcadccd.tar.gz coreclr-ee680783778ed0abb186ae41a8c861d5cdcadccd.tar.bz2 coreclr-ee680783778ed0abb186ae41a8c861d5cdcadccd.zip |
Merge pull request #5875 from pgavlin/JitStdoutVbuf
Disable buffering on jitstdout.
-rwxr-xr-x | src/jit/ee_il_dll.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/jit/ee_il_dll.cpp b/src/jit/ee_il_dll.cpp index f51e4521e3..e4d05739b6 100755 --- a/src/jit/ee_il_dll.cpp +++ b/src/jit/ee_il_dll.cpp @@ -76,6 +76,10 @@ void __stdcall jitStartup(ICorJitHost* jitHost) _setmode(jitstdoutFd, _O_TEXT); jitstdout = _fdopen(jitstdoutFd, "w"); assert(jitstdout != nullptr); + + // Prevent the FILE* from buffering its output in order to avoid calls to + // `fflush()` throughout the code. + setvbuf(jitstdout, nullptr, _IONBF, 0); } #endif |