diff options
author | Karel Zak | 2013-08-21 14:38:38 +0200 |
---|---|---|
committer | Karel Zak | 2013-08-21 14:38:38 +0200 |
commit | 6195f9e6fab612694ff97e66f9b276b913aa2d24 (patch) | |
tree | e20e772ab6cf20504268c1e776f3cfe6913fd21f /sys-utils/mount.c | |
parent | libmount: add reference counting to libmnt_cache (diff) | |
download | kernel-qcow2-util-linux-6195f9e6fab612694ff97e66f9b276b913aa2d24.tar.gz kernel-qcow2-util-linux-6195f9e6fab612694ff97e66f9b276b913aa2d24.tar.xz kernel-qcow2-util-linux-6195f9e6fab612694ff97e66f9b276b913aa2d24.zip |
misc: use libmnt_cache reference counting
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'sys-utils/mount.c')
-rw-r--r-- | sys-utils/mount.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sys-utils/mount.c b/sys-utils/mount.c index 0998b0110..9d9784905 100644 --- a/sys-utils/mount.c +++ b/sys-utils/mount.c @@ -163,7 +163,7 @@ static void print_all(struct libmnt_context *cxt, char *pattern, int show_label) free(xsrc); } - mnt_free_cache(cache); + mnt_unref_cache(cache); mnt_free_iter(itr); } @@ -990,8 +990,7 @@ int main(int argc, char **argv) * make a connection between the fstab and the canonicalization * cache. */ - struct libmnt_cache *cache = mnt_context_get_cache(cxt); - mnt_table_set_cache(fstab, cache); + mnt_table_set_cache(fstab, mnt_context_get_cache(cxt)); } if (!mnt_context_get_source(cxt) && |