From: Dave Reisner Date: Fri, 16 Nov 2012 04:18:07 +0000 (-0500) Subject: umount: (recursive) add a cache to the table X-Git-Tag: v2.23-rc1~515 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7b4a2697b17dcb9c1d7b1a51f03fbcc3638a2c7b;p=thirdparty%2Futil-linux.git umount: (recursive) add a cache to the table Without this table libmount will not resolve paths, meaning that umounting by relative path will fail. [kzak@redhat.com: - use mnt_context_get_cache() to make it sensitive to --no-canonicalize cmdline option] Signed-off-by: Dave Reisner Signed-off-by: Karel Zak --- diff --git a/sys-utils/umount.c b/sys-utils/umount.c index b21e396740..06d33de1d7 100644 --- a/sys-utils/umount.c +++ b/sys-utils/umount.c @@ -374,6 +374,8 @@ static int umount_recursive(struct libmnt_context *cxt, const char *spec) err(MOUNT_EX_SYSERR, _("libmount table allocation failed")); mnt_table_set_parser_errcb(tb, table_parser_errcb); + mnt_table_set_cache(tb, mnt_context_get_cache(cxt)); + /* * Don't use mtab here. The recursive umount depends on child-parent * relationship defined by mountinfo file.