sfdisk: return deterministic value from sfdisk_deinit()

disk-utils/sfdisk.c:222:9: warning: variable 'rc' is uninitialized when
used here [-Wuninitialized]
        return rc;
disk-utils/sfdisk.c:208:8: note: initialize the variable 'rc' to silence
this warning
        int rc;

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
Sami Kerola 2014-10-26 22:07:06 +00:00 committed by Karel Zak
parent 346dc42381
commit 5d36513976
1 changed files with 1 additions and 2 deletions

View File

@ -205,7 +205,6 @@ static void sfdisk_init(struct sfdisk *sf)
static int sfdisk_deinit(struct sfdisk *sf)
{
struct fdisk_context *parent;
int rc;
assert(sf);
assert(sf->cxt);
@ -219,7 +218,7 @@ static int sfdisk_deinit(struct sfdisk *sf)
fdisk_unref_context(sf->cxt);
memset(sf, 0, sizeof(*sf));
return rc;
return 0;
}
static void backup_sectors(struct sfdisk *sf,