summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorKarel Zak2009-02-18 15:34:51 +0100
committerKarel Zak2009-02-18 15:34:51 +0100
commitfb429f2219f004900f7646d8e6afa96df0e87667 (patch)
tree6ef6238b9d44205002789ebbad955c0449312ae5 /lib
parentfsck: link with generic fsprobe wrapper (diff)
downloadkernel-qcow2-util-linux-fb429f2219f004900f7646d8e6afa96df0e87667.tar.gz
kernel-qcow2-util-linux-fb429f2219f004900f7646d8e6afa96df0e87667.tar.xz
kernel-qcow2-util-linux-fb429f2219f004900f7646d8e6afa96df0e87667.zip
fsck: cosmetic changes (NLS, paths, ...)
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/ismounted.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/ismounted.c b/lib/ismounted.c
index 85f4ab30c..4c164a954 100644
--- a/lib/ismounted.c
+++ b/lib/ismounted.c
@@ -17,6 +17,7 @@
#include <sys/stat.h>
#include <ctype.h>
+#include "pathnames.h"
#include "ismounted.h"
/*
@@ -66,7 +67,7 @@ static int check_mntent_file(const char *mtab_file, const char *file,
int retval = 0;
dev_t file_dev=0, file_rdev=0;
ino_t file_ino=0;
- FILE *f;
+ FILE *f;
char buf[1024], *device = 0, *mnt_dir = 0, *cp;
*mount_flags = 0;
@@ -172,13 +173,13 @@ int is_mounted(const char *file)
int mount_flags = 0;
#ifdef __linux__
- retval = check_mntent_file("/proc/mounts", file, &mount_flags);
+ retval = check_mntent_file(_PATH_PROC_MOUNTS, file, &mount_flags);
if (retval)
return 0;
if (mount_flags)
return 1;
#endif /* __linux__ */
- retval = check_mntent_file("/etc/mtab", file, &mount_flags);
+ retval = check_mntent_file(_PATH_MOUNTED, file, &mount_flags);
if (retval)
return 0;
return mount_flags;