From 4ca49b389abcee8faac0513e7acaaeda157c323a Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Thu, 5 Jan 2017 12:40:10 +0100 Subject: csource: fix fork bomb --- csource/csource.go | 1 + 1 file changed, 1 insertion(+) (limited to 'csource') diff --git a/csource/csource.go b/csource/csource.go index 517112038..6d4d3d46e 100644 --- a/csource/csource.go +++ b/csource/csource.go @@ -85,6 +85,7 @@ func Write(p *prog.Prog, opts Options) ([]byte, error) { fmt.Fprint(w, "\t\tif (fork() == 0) {\n") fmt.Fprintf(w, "\t\t\tsetup_main_process(i, %v);\n", enableTun) fmt.Fprintf(w, "\t\t\tdo_sandbox_%v();\n", opts.Sandbox) + fmt.Fprint(w, "\t\t\treturn 0;\n") fmt.Fprint(w, "\t\t}\n") fmt.Fprint(w, "\t}\n") fmt.Fprint(w, "\tsleep(1000000);\n") -- cgit mrf-deployment