]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
fdisk: fix compiler warning [-Wmaybe-uninitialized]
authorKarel Zak <kzak@redhat.com>
Thu, 3 May 2018 08:30:51 +0000 (10:30 +0200)
committerKarel Zak <kzak@redhat.com>
Wed, 11 Jul 2018 13:39:25 +0000 (15:39 +0200)
Reported-by: L A Walsh <lkml@tlinx.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
disk-utils/fdisk.c

index 95bc83696814e3419c7223c25de890c644a8dce6..55af8dc11292a877a6f226de62e1b67388ccbd43 100644 (file)
@@ -271,7 +271,7 @@ static int ask_number(struct fdisk_context *cxt,
 
        do {
                int rc = get_user_reply(prompt, buf, bufsz);
-               uint64_t num;
+               uint64_t num = 0;
 
                if (rc)
                        return rc;