diff --git a/services/init/init_common_service.c b/services/init/init_common_service.c index 0cffe4c259c5eb7c41dfc26c542a66ab8f48eab2..61fc595eb5b8ff1eb79fd10770d1633e66a2b7b0 100755 --- a/services/init/init_common_service.c +++ b/services/init/init_common_service.c @@ -80,9 +80,6 @@ static int SetPerms(const Service *service) } } - // umask call always succeeds and return the previous mask value which is not needed here - (void)umask(DEFAULT_UMASK_INIT); - struct __user_cap_header_struct capHeader; capHeader.version = _LINUX_CAPABILITY_VERSION_3; capHeader.pid = 0; diff --git a/services/init/standard/init.c b/services/init/standard/init.c index ceb464efc05c3f569fcd4b1097d8c7cc6a386eca..e66b4df14f13ebb2cf2bc330ca5fda7034e2866a 100755 --- a/services/init/standard/init.c +++ b/services/init/standard/init.c @@ -91,6 +91,8 @@ static int FdHolderSockInit(void) void SystemInit(void) { SignalInit(); + // umask call always succeeds and return the previous mask value which is not needed here + (void)umask(DEFAULT_UMASK_INIT); MakeDirRecursive("/dev/unix/socket", S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH); int sock = FdHolderSockInit(); if (sock >= 0) {