summaryrefslogtreecommitdiffstats
path: root/init
diff options
context:
space:
mode:
authorNick Kralevich <nnk@google.com>2013-09-17 15:04:45 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2013-09-17 15:04:45 -0700
commit18c34183d76be2efbf2f498ec0185c1ceffa49f0 (patch)
treed275a7a4217c05654c5071e5a42cc913a7b0d9ef /init
parente6e5daace55672b1ec8fb6c5c17a85ee1531f7ad (diff)
parent5535b05120fa3fd3d68a09e01284aba35cc6e058 (diff)
downloadsystem_core-18c34183d76be2efbf2f498ec0185c1ceffa49f0.zip
system_core-18c34183d76be2efbf2f498ec0185c1ceffa49f0.tar.gz
system_core-18c34183d76be2efbf2f498ec0185c1ceffa49f0.tar.bz2
am 5535b051: write_file: introduce O_NOFOLLOW, use sane mask
* commit '5535b05120fa3fd3d68a09e01284aba35cc6e058': write_file: introduce O_NOFOLLOW, use sane mask
Diffstat (limited to 'init')
-rw-r--r--init/builtins.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/init/builtins.c b/init/builtins.c
index bfc0ddb..e8c8f91 100644
--- a/init/builtins.c
+++ b/init/builtins.c
@@ -57,7 +57,7 @@ static int write_file(const char *path, const char *value)
{
int fd, ret, len;
- fd = open(path, O_WRONLY|O_CREAT, 0622);
+ fd = open(path, O_WRONLY|O_CREAT|O_NOFOLLOW, 0600);
if (fd < 0)
return -errno;