Fixed the exec-key option.
authorMarkus Kauppila <markus.kauppila@gmail.com>
Sun, 14 Aug 2011 21:27:47 +0300
changeset 5831 d0f31485bd81
parent 5830 e1a6cc820772
child 5832 29fd178167c6
Fixed the exec-key option.
test/test-automation/src/runner/runner.c
--- a/test/test-automation/src/runner/runner.c	Sun Aug 14 21:05:08 2011 +0300
+++ b/test/test-automation/src/runner/runner.c	Sun Aug 14 21:27:47 2011 +0300
@@ -1209,7 +1209,15 @@
 
     	  // \todo User given string should be handled as a string
     	  // representing a hex digit
-    	  userExecKey = atoi(execKeyString);
+    	  //userExecKey = atoi(execKeyString);
+
+    	  int ret = sscanf(execKeyString, "%llx", &userExecKey);
+    	  if(ret != 1) {
+    		  fprintf(stderr, "Error: Failed to parse exec-key option");
+    		  exit(1);
+    	  }
+
+    	  printf("%Lx", userExecKey);
       }
       else if(SDL_strcmp(arg, "--test") == 0 || SDL_strcmp(arg, "-t") == 0) {
     	  only_selected_test = 1;