summaryrefslogtreecommitdiff
path: root/src/init
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2017-08-28 13:44:58 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2017-08-28 13:44:58 +0000
commit8f96addc9ab6285d7cd2d23725d029298375fd90 (patch)
tree6cfe374c9d6752fcbf7221a6aba635538dd48585 /src/init
parentc29368d9e34fee0e2fe0fae2fdf2865580be4ae0 (diff)
downloads6-linux-init-8f96addc9ab6285d7cd2d23725d029298375fd90.tar.xz
Add "redirfd -w 2 /dev/null" to namespace test in .s6-svscan/finish
Diffstat (limited to 'src/init')
-rw-r--r--src/init/s6-linux-init-maker.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/init/s6-linux-init-maker.c b/src/init/s6-linux-init-maker.c
index 2aa28da..71d82cb 100644
--- a/src/init/s6-linux-init-maker.c
+++ b/src/init/s6-linux-init-maker.c
@@ -108,7 +108,7 @@ static int finish_script (buffer *b)
if (in_namespace)
{
- if (buffer_puts(b, "ifelse { redirfd -r 0 ") < 0
+ if (buffer_puts(b, "ifelse { redirfd -w 2 /dev/null redirfd -r 0 ") < 0
|| buffer_put(b, satmp.s + sabase, satmp.len - sabase) < 0
|| buffer_puts(b, "/" EXITCODENAME " exit 0 }\n{ redirfd -r 0 ") < 0
|| buffer_put(b, satmp.s + sabase, satmp.len - sabase) < 0