summaryrefslogtreecommitdiffstats
path: root/shlibs/mount/src/tab_parse.c
diff options
context:
space:
mode:
authorKarel Zak2010-08-05 12:35:54 +0200
committerKarel Zak2011-01-03 12:28:40 +0100
commitbe1a5180596aa3a413e9c8047d0d25f4704756ef (patch)
tree747ea4dc2ee4176084ae076a815381bdd293ff72 /shlibs/mount/src/tab_parse.c
parentfindmnt: add support for fs-root (subvolumes and bind mounts) (diff)
downloadkernel-qcow2-util-linux-be1a5180596aa3a413e9c8047d0d25f4704756ef.tar.gz
kernel-qcow2-util-linux-be1a5180596aa3a413e9c8047d0d25f4704756ef.tar.xz
kernel-qcow2-util-linux-be1a5180596aa3a413e9c8047d0d25f4704756ef.zip
libmount: correctly use "none" values
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'shlibs/mount/src/tab_parse.c')
-rw-r--r--shlibs/mount/src/tab_parse.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/shlibs/mount/src/tab_parse.c b/shlibs/mount/src/tab_parse.c
index 4ab39fbd1..6f8308e50 100644
--- a/shlibs/mount/src/tab_parse.c
+++ b/shlibs/mount/src/tab_parse.c
@@ -206,7 +206,10 @@ static int mnt_parse_mountinfo_line(mnt_fs *fs, char *s)
fs->fs_optstr = next_word(&s);
if (!fs->fs_optstr)
return 1;
-
+ if (!strcmp(fs->fs_optstr, "none")) {
+ free(fs->fs_optstr);
+ fs->fs_optstr = NULL;
+ }
return 0;
}