]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
libmount: (context) avoid dead store
authorThomas Weißschuh <thomas@t-8ch.de>
Sun, 24 Dec 2023 11:44:35 +0000 (12:44 +0100)
committerThomas Weißschuh <thomas@t-8ch.de>
Sun, 31 Dec 2023 12:06:02 +0000 (13:06 +0100)
Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
libmount/src/context.c

index be216708f988f2620e234faf3d1a63c3fd44afc0..6db71f4e4777f4b072765893aa40c75cae05a9b7 100644 (file)
@@ -3411,10 +3411,8 @@ static int test_mountall(struct libmnt_test *ts __attribute__((unused)),
                        mnt_context_set_options_pattern(cxt, argv[idx + 1]);
                        idx += 2;
                }
-               if (argv[idx] && !strcmp(argv[idx], "-t")) {
+               if (argv[idx] && !strcmp(argv[idx], "-t"))
                        mnt_context_set_fstype_pattern(cxt, argv[idx + 1]);
-                       idx += 2;
-               }
        }
 
        while (mnt_context_next_mount(cxt, itr, &fs, &mntrc, &ignored) == 0) {