aboutsummaryrefslogtreecommitdiffstats
path: root/erts
diff options
context:
space:
mode:
authorFredrik Gustafsson <[email protected]>2013-07-29 16:48:57 +0200
committerFredrik Gustafsson <[email protected]>2013-07-29 16:48:57 +0200
commit9f25957c462dc7d8b74f90b42cb2443a7ed74a73 (patch)
treed58eb49b5304decc4c58dbdc82da18e88021a803 /erts
parent989daf58ebeec07c7f15325ff7b843e02d28e810 (diff)
parenta5fc79292b9b018cd39d104a8cd2e79de141e3ad (diff)
downloadotp-9f25957c462dc7d8b74f90b42cb2443a7ed74a73.tar.gz
otp-9f25957c462dc7d8b74f90b42cb2443a7ed74a73.tar.bz2
otp-9f25957c462dc7d8b74f90b42cb2443a7ed74a73.zip
Merge branch 'maint'
Diffstat (limited to 'erts')
-rw-r--r--erts/etc/unix/run_erl.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/erts/etc/unix/run_erl.c b/erts/etc/unix/run_erl.c
index 53c779b1be..b69e31f784 100644
--- a/erts/etc/unix/run_erl.c
+++ b/erts/etc/unix/run_erl.c
@@ -1142,6 +1142,14 @@ static void daemon_init(void)
sf_close(i);
}
+ /* Necessary on some platforms */
+
+ open("/dev/null", O_RDONLY); /* Order is important! */
+ open("/dev/null", O_WRONLY);
+ open("/dev/null", O_WRONLY);
+
+ errno = 0; /* if set by open */
+
OPEN_SYSLOG();
run_daemon = 1;
}