From: Marco Costalba Date: Sat, 17 Dec 2011 15:56:36 +0000 (+0100) Subject: Disable again buffering at startup X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=a77a3b723f1cb7ddcb9313888d779b48551e0501;p=stockfish Disable again buffering at startup Partially revert efd21679980dfd59 Without this patch SF does not send "bestmove" to GUI. No functional change. Signed-off-by: Marco Costalba --- diff --git a/src/main.cpp b/src/main.cpp index 1a830970..fcb7e40c 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -17,6 +17,7 @@ along with this program. If not, see . */ +#include #include #include @@ -35,6 +36,9 @@ extern void kpk_bitbase_init(); int main(int argc, char* argv[]) { + // Disable output buffering: printf() does not work correctly otherwise + setvbuf(stdout, NULL, _IONBF, 0); + bitboards_init(); Position::init(); kpk_bitbase_init();