From: Karel Zak Date: Mon, 18 Sep 2006 01:23:46 +0000 (-0400) Subject: Fix blkid bug with correctly reporting FAT filesystem labels that are empty X-Git-Tag: E2FSPROGS-1_40-WIP-1114~46 X-Git-Url: https://git.whamcloud.com/gitweb?a=commitdiff_plain;h=633f453db14b0fb91294887a9629f5cc2f95407f;p=tools%2Fe2fsprogs.git Fix blkid bug with correctly reporting FAT filesystem labels that are empty Signed-off-by: Karel Zak --- diff --git a/lib/blkid/ChangeLog b/lib/blkid/ChangeLog index 4f46942..e4939e0 100644 --- a/lib/blkid/ChangeLog +++ b/lib/blkid/ChangeLog @@ -1,3 +1,7 @@ +2006-09-17 Karel Zak + + * probe.c (probe_fat): Fix problem with empty FAT label. + 2006-09-17 Karel Zak * probe.c (probe_gfs, _gfs2), probe.h: Add support for GFS/GFS2 diff --git a/lib/blkid/probe.c b/lib/blkid/probe.c index f06a5d0..0f16565 100644 --- a/lib/blkid/probe.c +++ b/lib/blkid/probe.c @@ -350,8 +350,8 @@ static int probe_fat(struct blkid_probe *probe, } if (vol_label && memcmp(vol_label, no_name, 11)) { - label = vol_label; - label_len = figure_label_len(vol_label, 11); + if ((label_len = figure_label_len(vol_label, 11))) + label = vol_label; } /* We can't just print them as %04X, because they are unaligned */