]> git.sesse.net Git - stockfish/blobdiff - src/search.cpp
Teach Benchmark to read positions from a file
[stockfish] / src / search.cpp
index c846812ed56ed87e8c49ae02a62209427f5f748e..e4675df56ea35b75b39a14c9672e901310d3f6e5 100644 (file)
@@ -342,7 +342,7 @@ void think(const Position &pos, bool infinite, bool ponder, int time,
   TT.set_size(get_option_value_int("Hash"));
   if(button_was_pressed("Clear Hash"))
     TT.clear();
-  PonderingEnabled = get_option_value_int("Ponder");
+  PonderingEnabled = get_option_value_bool("Ponder");
   MultiPV = get_option_value_int("MultiPV");
 
   CheckExtension[1] = Depth(get_option_value_int("Check Extension (PV nodes)"));
@@ -2135,7 +2135,7 @@ namespace {
     if(data) {
       char input[256];
       if(fgets(input, 255, stdin) == NULL)
-        strcpy(input, "quit\n");
+        strncpy(input, "quit\n", 5);
       if(strncmp(input, "quit", 4) == 0) {
         AbortSearch = true;
         PonderSearch = false;