Compare getopt_long return value against -1, not EOF. Use NULL, not '(int *) 0'...
[platform/upstream/coreutils.git] / src / cksum.c
index 2318d5b..c3f06eb 100644 (file)
@@ -293,7 +293,7 @@ main (int argc, char **argv)
 
   have_read_stdin = 0;
 
-  while ((c = getopt_long (argc, argv, "", long_options, (int *) 0)) != EOF)
+  while ((c = getopt_long (argc, argv, "", long_options, NULL)) != -1)
     {
       switch (c)
        {