pspp-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pspp-cvs] Changes to pspp/src/cmdline.c


From: Ben Pfaff
Subject: [Pspp-cvs] Changes to pspp/src/cmdline.c
Date: Sat, 10 Dec 2005 21:48:47 -0500

Index: pspp/src/cmdline.c
diff -u pspp/src/cmdline.c:1.13 pspp/src/cmdline.c:1.14
--- pspp/src/cmdline.c:1.13     Sun Jul 31 21:42:46 2005
+++ pspp/src/cmdline.c  Sun Dec 11 02:48:45 2005
@@ -52,7 +52,6 @@
 void
 parse_command_line (int argc, char **argv)
 {
-  static int testing_mode = 0;
   static struct option long_options[] =
   {
     {"algorithm", required_argument, NULL, 'a'},
@@ -73,7 +72,7 @@
     {"recon", no_argument, NULL, 'n'},
     {"safer", no_argument, NULL, 's'},
     {"syntax", required_argument, NULL, 'x'},
-    {"testing-mode", no_argument, &testing_mode, 1},
+    {"testing-mode", no_argument, NULL, 'T'},
     {"verbose", no_argument, NULL, 'v'},
     {"version", no_argument, NULL, 'V'},
     {0, 0, 0, 0},
@@ -81,8 +80,8 @@
 
   int c, i;
 
-  int cleared_device_defaults = 0;
-  int no_statrc = 0;
+  bool cleared_device_defaults = false;
+  bool no_statrc = false;
 
   for (;;)
     {
@@ -168,7 +167,7 @@
          if (!cleared_device_defaults)
            {
              outp_configure_clear ();
-             cleared_device_defaults = 1;
+             cleared_device_defaults = true;
            }
          outp_configure_add (optarg);
          break;
@@ -177,10 +176,10 @@
           putchar('\n');
          break;
        case 'r':
-         no_statrc = 1;
+         no_statrc = true;
          break;
        case 's':
-         make_safe();
+         set_safer_mode ();
          break;
        case 'v':
          err_verbosity++;
@@ -189,6 +188,10 @@
          puts (version);
          puts (legal);
          err_hcf (1);
+        case 'T':
+          force_long_view ();
+          set_testing_mode (true);
+          break;
        case '?':
          usage ();
          assert (0);
@@ -198,15 +201,6 @@
          assert (0);
        }
     }
-
-
-  if (testing_mode)
-    {
-      /* FIXME: Later this option should do some other things, too. */
-      force_long_view();
-      test_mode = 1;
-    }
-    
 
   for (i = optind; i < argc; i++)
     {




reply via email to

[Prev in Thread] Current Thread [Next in Thread]