about summary refs log tree commit diff
path: root/sourcecodes/test_set_predictions.php
diff options
context:
space:
mode:
Diffstat (limited to 'sourcecodes/test_set_predictions.php')
-rw-r--r--sourcecodes/test_set_predictions.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/sourcecodes/test_set_predictions.php b/sourcecodes/test_set_predictions.php
index 076188b4..f1806575 100644
--- a/sourcecodes/test_set_predictions.php
+++ b/sourcecodes/test_set_predictions.php
@@ -189,7 +189,9 @@ if($searchID!="")
     {
       //      $fpdata = fopen("./data/".$keyval."ts_input.txt","w");
       $fpdata = fopen($dir.$keyval."ts_upload.txt","w");
-      fwrite($fpdata,$searchID);
+      if ($fpdata !== false) {
+        fwrite($fpdata,$searchID);
+      }
     }
   $command = './run_scripts/run_test_set '.$keyval;
   $output = shell_exec("$command > /dev/null 2 > /dev/null &");