changeset 1593:f2cac60ab2d3 draft

Switching on fortify was not kind to the pending directory. Fix the actual build break (open(O_CREAT) without permissions).
author Rob Landley <rob@landley.net>
date Tue, 02 Dec 2014 03:12:58 -0600
parents c0dee3caad31
children 9b906eb047e8
files toys/pending/dhcpd.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/toys/pending/dhcpd.c	Tue Dec 02 03:05:01 2014 -0600
+++ b/toys/pending/dhcpd.c	Tue Dec 02 03:12:58 2014 -0600
@@ -867,7 +867,7 @@
   struct arg_list *listdls = gstate.dleases;
   dyn_lease *dls;
 
-  if ((fd = open(gconfig.lease_file, O_WRONLY | O_CREAT | O_TRUNC)) < 0) {
+  if ((fd = open(gconfig.lease_file, O_WRONLY | O_CREAT | O_TRUNC, 0600)) < 0) {
     perror_msg("can't open %s ", gconfig.lease_file);
     return fd;
   }