From 27dd495b98a6135554b1d839fefe436ba3c6ca71 Mon Sep 17 00:00:00 2001 From: Bernhard Reutner-Fischer Date: Mon, 18 Feb 2008 18:35:53 +0000 Subject: - fix open(creat) without a mode --- miscutils/crontab.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'miscutils/crontab.c') diff --git a/miscutils/crontab.c b/miscutils/crontab.c index 6b6896469..cb261ed18 100644 --- a/miscutils/crontab.c +++ b/miscutils/crontab.c @@ -214,7 +214,7 @@ int crontab_main(int argc, char **argv) /* Bump notification file. Handle window where crond picks file up * before we can write our entry out. */ - while ((fd = open(CRONUPDATE, O_WRONLY|O_CREAT|O_APPEND)) >= 0) { + while ((fd = open(CRONUPDATE, O_WRONLY|O_CREAT|O_APPEND, 0600)) >= 0) { struct stat st; fdprintf(fd, "%s\n", pas->pw_name); -- cgit v1.2.3