summaryrefslogtreecommitdiffstats
path: root/sys-utils/mountpoint.c
diff options
context:
space:
mode:
authorKarel Zak2013-02-14 15:46:06 +0100
committerKarel Zak2013-02-14 15:46:06 +0100
commit39edf68139a0cd8460281bae3fa39c51c760ad26 (patch)
tree9e81668e9e5ee36b724647ee235196c07faab298 /sys-utils/mountpoint.c
parentlscpu: don't read cpuid on non-live systems (diff)
downloadkernel-qcow2-util-linux-39edf68139a0cd8460281bae3fa39c51c760ad26.tar.gz
kernel-qcow2-util-linux-39edf68139a0cd8460281bae3fa39c51c760ad26.tar.xz
kernel-qcow2-util-linux-39edf68139a0cd8460281bae3fa39c51c760ad26.zip
mountpoint: don't hardcode paths
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'sys-utils/mountpoint.c')
-rw-r--r--sys-utils/mountpoint.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys-utils/mountpoint.c b/sys-utils/mountpoint.c
index 6ab813d72..c86e94b12 100644
--- a/sys-utils/mountpoint.c
+++ b/sys-utils/mountpoint.c
@@ -38,12 +38,13 @@
#include "xalloc.h"
#include "c.h"
#include "closestream.h"
+#include "pathnames.h"
static int quiet;
static int dir_to_device(const char *spec, dev_t *dev)
{
- struct libmnt_table *tb = mnt_new_table_from_file("/proc/self/mountinfo");
+ struct libmnt_table *tb = mnt_new_table_from_file(_PATH_PROC_MOUNTINFO);
struct libmnt_fs *fs;
struct libmnt_cache *cache;
int rc = -1;