From ec640140b34656fe35752aaaa20d128c301d24b5 Mon Sep 17 00:00:00 2001 From: Chris Toshok Date: Sat, 15 Mar 2003 00:34:11 +0000 Subject: ugh, we need to make sure the file is opened for writing. or the flags 2003-03-14 Chris Toshok * gal/util/e-util.c (e_write_file): ugh, we need to make sure the file is opened for writing. or the flags with O_WRONLY. svn path=/trunk/; revision=20304 --- e-util/e-util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'e-util') diff --git a/e-util/e-util.c b/e-util/e-util.c index b830f654ee..4e3584a059 100644 --- a/e-util/e-util.c +++ b/e-util/e-util.c @@ -198,7 +198,7 @@ e_write_file(const char *filename, const char *data, int flags) int fd; int length = strlen(data); int bytes; - fd = open(filename, flags, 0666); + fd = open(filename, flags | O_WRONLY, 0666); if (fd == -1) return errno; while (length > 0) { -- cgit