summaryrefslogtreecommitdiff
path: root/e2fsprogs/old_e2fsprogs/ext2fs
diff options
context:
space:
mode:
Diffstat (limited to 'e2fsprogs/old_e2fsprogs/ext2fs')
-rw-r--r--e2fsprogs/old_e2fsprogs/ext2fs/ismounted.c2
-rw-r--r--e2fsprogs/old_e2fsprogs/ext2fs/test_io.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/e2fsprogs/old_e2fsprogs/ext2fs/ismounted.c b/e2fsprogs/old_e2fsprogs/ext2fs/ismounted.c
index d943f11..7f24f9b 100644
--- a/e2fsprogs/old_e2fsprogs/ext2fs/ismounted.c
+++ b/e2fsprogs/old_e2fsprogs/ext2fs/ismounted.c
@@ -249,7 +249,7 @@ static int is_swap_device(const char *file)
file_dev = st_buf.st_rdev;
#endif /* __GNU__ */
- if (!(f = fopen("/proc/swaps", "r")))
+ if (!(f = fopen_for_read("/proc/swaps")))
return 0;
/* Skip the first line */
fgets(buf, sizeof(buf), f);
diff --git a/e2fsprogs/old_e2fsprogs/ext2fs/test_io.c b/e2fsprogs/old_e2fsprogs/ext2fs/test_io.c
index bd74225..3d40d9a 100644
--- a/e2fsprogs/old_e2fsprogs/ext2fs/test_io.c
+++ b/e2fsprogs/old_e2fsprogs/ext2fs/test_io.c
@@ -180,7 +180,7 @@ static errcode_t test_open(const char *name, int flags, io_channel *channel)
data->outfile = NULL;
if ((value = getenv("TEST_IO_LOGFILE")) != NULL)
- data->outfile = fopen(value, "w");
+ data->outfile = fopen_for_write(value);
if (!data->outfile)
data->outfile = stderr;