#define NONE 2\r
#define ANALYZE 3\r
\r
-char move[2000][10], iniPos[256], hashOpt[20], pause, pondering, suspended, ponder, post, hasHash, c, sc='c', suffix[81], *variants, varOpt, searching;\r
+char move[2000][10], iniPos[256], hashOpt[20], pause, pondering, suspended, ponder, post, hasHash, c, sc='c', suffix[81], *variants, varOpt, searching, *binary;\r
int mps, tc, inc, sTime, depth, myTime, hisTime, stm, computer = NONE, memory, oldMem=0, cores, moveNr, lastDepth, lastScore, startTime, debug, flob;\r
int statDepth, statScore, statNodes, statTime, currNr, size, collect, nr, sm, inex, on[500], frc, byo = -1, namOpt, comp;\r
char currMove[20], moveMap[500][10], /* for analyze mode */ canPonder[20], threadOpt[20], varList[8000], anaOpt[20], backLog[10000], checkOptions[8192] = "Ponder";\r
fflush(stdout); fflush(toE);\r
while((line[i] = x = GetChar()) != EOF && line[i] != '\n') i++;\r
line[++i] = 0;\r
- if(x == EOF) exit(0);\r
+ if(x == EOF) printf("tellusererror UCI2WB: %s died on me\n", binary), exit(0);\r
DPRINT("# engine said: %s", line), fflush(stdout);\r
if(sscanf(line, "%s", command) != 1) continue;\r
if(!strcmp(command, "bestmove")) {\r
else if(sc == 'n') sc = 'c'; // UCI for normal Chess\r
\r
// spawn engine proc\r
- if(StartEngine(argv[1], dir) != NO_ERROR) { perror(argv[1]), exit(-1); }\r
+ if(StartEngine(binary = argv[1], dir) != NO_ERROR) { perror(argv[1]), exit(-1); }\r
\r
Sync(INIT);\r
\r