From 3d604b43675fd893658eb1db85b8f313f5064b5d Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Tue, 1 Mar 2011 15:31:49 +0100 Subject: [PATCH] libblkid: fix gcc warnings Signed-off-by: Karel Zak --- shlibs/blkid/src/partitions/gpt.c | 2 +- shlibs/blkid/src/read.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/shlibs/blkid/src/partitions/gpt.c b/shlibs/blkid/src/partitions/gpt.c index 7df17bb1e..9281a8943 100644 --- a/shlibs/blkid/src/partitions/gpt.c +++ b/shlibs/blkid/src/partitions/gpt.c @@ -289,7 +289,7 @@ static struct gpt_header *get_gpt_header( static int probe_gpt_pt(blkid_probe pr, const struct blkid_idmag *mag) { - uint64_t lastlba, lba; + uint64_t lastlba = 0, lba; struct gpt_header hdr, *h; struct gpt_entry *e; blkid_parttable tab = NULL; diff --git a/shlibs/blkid/src/read.c b/shlibs/blkid/src/read.c index 3ff9ebe9f..c404bb010 100644 --- a/shlibs/blkid/src/read.c +++ b/shlibs/blkid/src/read.c @@ -305,8 +305,8 @@ static int parse_xml(char **name, char **value, char **cp) */ static int parse_tag(blkid_cache cache, blkid_dev dev, char **cp) { - char *name; - char *value; + char *name = NULL; + char *value = NULL; int ret; if (!cache || !dev)