From ab8c6e056931440fcd432dc7977328a4d91aab92 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Fri, 2 Mar 2012 13:29:39 +0100 Subject: libmount: add mnt_fs_streq_srcpath() We have to be careful with "none" or another dummy sources for pseudo filesystems. These strings should be canonicalized or compared as a paths. The function is not exported by library API. Signed-off-by: Karel Zak --- sys-utils/mount.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sys-utils/mount.c') diff --git a/sys-utils/mount.c b/sys-utils/mount.c index 8f5dcdbd6..8c94052e5 100644 --- a/sys-utils/mount.c +++ b/sys-utils/mount.c @@ -423,7 +423,7 @@ try_readonly: const char *s = mnt_fs_get_srcpath(fs), *t = mnt_fs_get_target(fs); - if (t && s && streq_except_trailing_slash(s, src)) + if (t && s && mnt_fs_streq_strpath(fs, src)) fprintf(stderr, _( " %s is already mounted on %s\n"), s, t); } -- cgit v1.2.3-55-g7522