Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Fix parsing of options for testall.
[simgrid.git] / tools / sg_unit_extractor.pl
index 1c62859..031329a 100755 (executable)
@@ -148,11 +148,11 @@ int main(int argc, char *argv[]) {
           strcat(selection, \",\");
           strcat(selection, p);
         }
           strcat(selection, \",\");
           strcat(selection, p);
         }
-      } else if (!strncmp(argv[i],\"--dump-only\",strlen(\"--dump-only\"))||
-                !strncmp(argv[i],\"--dump\",     strlen(\"--dump\"))) {
+      } else if (!strcmp(argv[i], \"--dump-only\")||
+                 !strcmp(argv[i], \"--dump\")) {
         xbt_test_dump(selection);
         return 0;
         xbt_test_dump(selection);
         return 0;
-      } else if (!strncmp(argv[i],\"--help\",strlen(\"--help\"))) {
+      } else if (!strcmp(argv[i], \"--help\")) {
          printf(
              "Usage: testall [--help] [--tests=selection] [--dump-only]\\n\\n"
              "--help: display this help\\n"
          printf(
              "Usage: testall [--help] [--tests=selection] [--dump-only]\\n\\n"
              "--help: display this help\\n"
@@ -240,7 +240,7 @@ EOF
           last if /SGU: BEGIN SUITES DECLARATION/;
        }
        
           last if /SGU: BEGIN SUITES DECLARATION/;
        }
        
-       ### Done with prototypes. And now, the actual code
+       ### Done with prototypes. And now, the actual code
        
        # search my prototype
        while (<IN>) {
        
        # search my prototype
        while (<IN>) {