usr/gen_init_cpio.c: remove unnecessary -1 values from int file
authorLi zeming <zeming@nfschina.com>
Mon, 19 Sep 2022 01:44:06 +0000 (09:44 +0800)
committerAndrew Morton <akpm@linux-foundation.org>
Mon, 3 Oct 2022 21:21:44 +0000 (14:21 -0700)
The file variable is assigned first, it does not need to be initialized.

Link: https://lkml.kernel.org/r/20220919014406.3242-1-zeming@nfschina.com
Signed-off-by: Li zeming <zeming@nfschina.com>
Cc: Li zeming <zeming@nfschina.com>
Cc: Masahiro Yamada <masahiroy@kernel.org>
Cc: Nicolas Schier <nicolas@fjasle.eu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
usr/gen_init_cpio.c

index dc838e2..ee01e40 100644 (file)
@@ -326,7 +326,7 @@ static int cpio_mkfile(const char *name, const char *location,
        char s[256];
        struct stat buf;
        unsigned long size;
-       int file = -1;
+       int file;
        int retval;
        int rc = -1;
        int namesize;