X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=hachu.c;h=fdf5bb401dd4d0517907ac6965c87ad9c552f8c4;hb=73f8d53961524d71089ad54b1549a953efa0fe14;hp=52355e8383a3fe8558198d292b1cbf88721c0015;hpb=5fb50eb40d403682ab52214f7dfb10271a48df9e;p=hachu.git diff --git a/hachu.c b/hachu.c index 52355e8..fdf5bb4 100644 --- a/hachu.c +++ b/hachu.c @@ -2646,16 +2646,18 @@ printf("# ponder hit\n"); main() { - int engineSide=NONE; // side played by engine + int engineSide=NONE; // side played by engine MOVE move; int i, score, curVarNr; - Init(V_CHU); // Chu + setvbuf(stdin, NULL, _IOLBF, 1024); // buffering more than one line flaws test for pending input! + + Init(V_CHU); // Chu seed = startTime = GetTickCount(); moveNr = 0; // initialize random while(1) { // infinite loop - fflush(stdout); // make sure everything is printed before we do something that might take time + fflush(stdout); // make sure everything is printed before we do something that might take time *inBuf = 0; if(moveNr >= 20) randomize = OFF; //if(moveNr >20) printf("resign\n");