]> git.cworth.org Git - fips/blobdiff - fips.c
Push final collection of CFLAGS/LDFLAGS from Makefile.config to Makefile.local
[fips] / fips.c
diff --git a/fips.c b/fips.c
index 370a2eefab16d28c25b74eb87b645cee2d3c1a9b..fca2da8ec7c6e6df1c9d199e8e3f5b470d088548 100644 (file)
--- a/fips.c
+++ b/fips.c
@@ -19,8 +19,8 @@
  * THE SOFTWARE.
  */
 
-#include <stdio.h>
-#include <stdlib.h>
+#include "fips.h"
+
 #include <limits.h>
 #include <getopt.h>
 
@@ -43,7 +43,17 @@ main (int argc, char *argv[])
 {
        int opt, ret;
 
-       const char *short_options = "h";
+       /* The initial '+' means that getopt will stop looking for
+        * options after the first non-option argument. This means
+        * that a command such as:
+        *
+        *      fips glxgears -fullscreen
+        *
+        * Will do what is intended, (namely, have fips invoke
+        * "glxgears -fullscreen" rather than trying to interpret
+        * -fullscreen as options to fips itself.
+        */
+       const char *short_options = "+h";
        const struct option long_options[] = {
                {"help", no_argument, 0, 'h'},
                {0, 0, 0, 0}