From 5a8ee1beee364559bac37376949de1ea01d00ae2 Mon Sep 17 00:00:00 2001 From: Fabricio Voznika Date: Thu, 16 Apr 2020 13:15:47 -0700 Subject: Preserve log FD after execve PiperOrigin-RevId: 306908296 --- runsc/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runsc/main.go b/runsc/main.go index 59f624842..c1c78529c 100644 --- a/runsc/main.go +++ b/runsc/main.go @@ -291,7 +291,7 @@ func main() { // want with them. Since Docker and Containerd both eat boot's stderr, we // dup our stderr to the provided log FD so that panics will appear in the // logs, rather than just disappear. - if err := syscall.Dup3(fd, int(os.Stderr.Fd()), syscall.O_CLOEXEC); err != nil { + if err := syscall.Dup3(fd, int(os.Stderr.Fd()), 0); err != nil { cmd.Fatalf("error dup'ing fd %d to stderr: %v", fd, err) } } -- cgit v1.2.3