From b2ec716534441d9dea42051ce8bf2c1df227685a Mon Sep 17 00:00:00 2001 From: Dan Everton Date: Tue, 30 May 2006 11:26:41 +0000 Subject: Use correct file mode when creating files. Fixes task 5452 git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10020 a1c6a512-1295-4272-9138-f99709370657 --- apps/plugins/calendar.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'apps/plugins/calendar.c') diff --git a/apps/plugins/calendar.c b/apps/plugins/calendar.c index 464d810342..a57cadedd2 100644 --- a/apps/plugins/calendar.c +++ b/apps/plugins/calendar.c @@ -316,7 +316,7 @@ static bool save_memo(int changed, bool new_mod, struct shown *shown) { int fp,fq; fp = rb->open("/.rockbox/.memo",O_RDONLY | O_CREAT); - fq = rb->creat("/.rockbox/~temp", 0); + fq = rb->creat("/.rockbox/~temp", O_WRONLY); if ( (fq != -1) && (fp != -1) ) { int i; @@ -345,7 +345,7 @@ static bool save_memo(int changed, bool new_mod, struct shown *shown) rb->write(fq,temp,1); } rb->close(fp); - fp = rb->creat("/.rockbox/.memo", 0); + fp = rb->creat("/.rockbox/.memo", O_WRONLY); rb->lseek(fp, 0, SEEK_SET); rb->lseek(fq, 0, SEEK_SET); for (i = 0; i < rb->filesize(fq); i++) -- cgit v1.2.3