Ensure resolv.conf is created with the correct umask.
authorRoy Marples <roy@marples.name>
Wed, 28 Nov 2007 13:01:10 +0000 (13:01 +0000)
committerRoy Marples <roy@marples.name>
Wed, 28 Nov 2007 13:01:10 +0000 (13:01 +0000)
libc.in

diff --git a/libc.in b/libc.in
index ba0cbdd46c6e77d22e53b7b8b63157e9df9e8494..83d25191a0ff7d34a13dfc493efecc5aef101e44 100755 (executable)
--- a/libc.in
+++ b/libc.in
@@ -139,7 +139,7 @@ if [ -e "${RESOLVCONF}"/run/resolv.conf ]; then
 fi
 
 # Create our resolv.conf now
-printf "${NEWCONF}" > "${RESOLVCONF}"/run/resolv.conf
+(umask 022; printf "${NEWCONF}" > "${RESOLVCONF}"/run/resolv.conf)
 
 resolvconf -s nscd restart