]> git.ipfire.org Git - thirdparty/e2fsprogs.git/commitdiff
filefrag: fix GCC7.x compiler warning
authorMarc Thomas <marc@dragonfly.plus.com>
Mon, 26 Jun 2017 15:39:47 +0000 (16:39 +0100)
committerTheodore Ts'o <tytso@mit.edu>
Wed, 28 Jun 2017 17:19:58 +0000 (13:19 -0400)
../../misc/filefrag.c:591:33: warning: comparison between pointer and
zero character constant [-Wpointer-compare]
  for (cpp = argv + optind; *cpp != '\0'; cpp++) {

Signed-off-by: Marc Thomas <marc@dragonfly.plus.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
misc/filefrag.c

index 1a185124509b741ecb3c8ba641b2c4b37564e786..9c57ab930ac1856a38b0452032e54aacd89cf32b 100644 (file)
@@ -588,7 +588,7 @@ int main(int argc, char**argv)
        if (optind == argc)
                usage(argv[0]);
 
-       for (cpp = argv + optind; *cpp != '\0'; cpp++) {
+       for (cpp = argv + optind; *cpp != NULL; cpp++) {
                int rc2 = frag_report(*cpp);
 
                if (rc2 < 0 && rc == 0)