summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiklos Szeredi <miklos@szeredi.hu>2010-11-08 15:47:36 +0100
committerMiklos Szeredi <mszeredi@suse.cz>2010-11-11 16:27:35 +0100
commitccb671bca8919f7c93fe703ee981e70f1dbcdd8e (patch)
tree38ce38e3b047ffd7db54731e9c719c72d4f97eb2
parent3a55cdd22237b6bcf188675c6123af124b967023 (diff)
downloadfuse-ccb671bca8919f7c93fe703ee981e70f1dbcdd8e.tar.gz
Open /dev/null for write
Open /dev/null for write instead of read for redirecting stdout and stderr
-rw-r--r--ChangeLog5
-rw-r--r--lib/mount_util.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 4fca566..fb3504b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2010-11-08 Miklos Szeredi <miklos@szeredi.hu>
+
+ * Open /dev/null for write instead of read for redirecting stdout
+ and stderr
+
2010-10-14 Miklos Szeredi <miklos@szeredi.hu>
Use LTLIBICONV when linking libfuse. This fixes building against
diff --git a/lib/mount_util.c b/lib/mount_util.c
index 33e6697..5469c1b 100644
--- a/lib/mount_util.c
+++ b/lib/mount_util.c
@@ -144,7 +144,7 @@ static int add_mount(const char *progname, const char *fsname,
* Hide output, because old versions don't support
* --no-canonicalize
*/
- int fd = open("/dev/null", O_RDONLY);
+ int fd = open("/dev/null", O_WRONLY);
dup2(fd, 1);
dup2(fd, 2);