]> git.sesse.net Git - ffmpeg/blobdiff - compat/getopt.c
lavu: Add av_gettime_relative
[ffmpeg] / compat / getopt.c
index 3e7d3e215ee3e684f78b975838c81489176ac587..b7adf60e2fdc91c274d368e3147a46c9343a0f22 100644 (file)
@@ -38,8 +38,6 @@ static int optind = 1;
 static int optopt;
 static char *optarg;
 
-#undef fprintf
-
 static int getopt(int argc, char *argv[], char *opts)
 {
     static int sp = 1;
@@ -55,7 +53,7 @@ static int getopt(int argc, char *argv[], char *opts)
             return EOF;
         }
     optopt = c = argv[optind][sp];
-    if (c == ':' || (cp = strchr(opts, c)) == NULL) {
+    if (c == ':' || !(cp = strchr(opts, c))) {
         fprintf(stderr, ": illegal option -- %c\n", c);
         if (argv[optind][++sp] == '\0') {
             optind++;