From 9d9429df54b098ada384fabbbf1453dea6c18d01 Mon Sep 17 00:00:00 2001 From: Tharre Date: Mon, 8 Jun 2015 16:13:40 +0200 Subject: Pass 0755 directly instead of using POSIX macros I'm not perfectly sure if this actually violates the POSIX standard or not, but in practice all systems seem to accept it. --- src/build.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/build.c b/src/build.c index 8192ebe..19ffa0d 100644 --- a/src/build.c +++ b/src/build.c @@ -347,8 +347,7 @@ void add_dep(const char *target, const char *parent, int ident) { fatal("redo: failed to open %s", dep_path); /* no dependency record was found, so we create one */ - mode_t mode = S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH; - fd = open(dep_path, O_WRONLY | O_APPEND | O_CREAT, mode); + fd = open(dep_path, O_WRONLY | O_APPEND | O_CREAT, 0755); if (fd < 0) fatal("redo: failed to open %s", dep_path); } -- cgit v1.2.3-70-g09d2