From: oetiker Date: Wed, 3 Apr 2002 05:32:31 +0000 (+0000) Subject: i suck. sorry. add ,0666 to the open(). -- Paul Vixie X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=37b2687fdcdd310be0aa5d622426e04820f92d3c;p=rrdtool.git i suck. sorry. add ,0666 to the open(). -- Paul Vixie git-svn-id: svn://svn.oetiker.ch/rrdtool/trunk/program@113 a5681a0c-68f1-0310-ab6d-d61299d08faa --- diff --git a/src/rrd_restore.c b/src/rrd_restore.c index 770e22f..e24cc8e 100644 --- a/src/rrd_restore.c +++ b/src/rrd_restore.c @@ -407,7 +407,7 @@ rrd_write(char *file_name, rrd_t *rrd) if (strcmp("-",file_name)==0){ *rrd_file= *stdout; } else { - int fd = open(file_name,O_RDWR|O_CREAT|O_EXCL); + int fd = open(file_name,O_RDWR|O_CREAT|O_EXCL,0666); if (fd == -1 || (rrd_file = fdopen(fd,"wb")) == NULL) { rrd_set_error("creating '%s': %s",file_name,strerror(errno)); rrd_free(rrd);