Merge pull request #812 from lubinszARM:pr_dup3_arm

PiperOrigin-RevId: 270957224
This commit is contained in:
gVisor bot 2019-09-24 12:06:38 -07:00
commit 91abeb1dbc
1 changed files with 1 additions and 1 deletions

View File

@ -239,7 +239,7 @@ func main() {
// want with them. Since Docker and Containerd both eat boot's stderr, we // 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 // dup our stderr to the provided log FD so that panics will appear in the
// logs, rather than just disappear. // logs, rather than just disappear.
if err := syscall.Dup2(int(f.Fd()), int(os.Stderr.Fd())); err != nil { if err := syscall.Dup3(int(f.Fd()), int(os.Stderr.Fd()), 0); err != nil {
cmd.Fatalf("error dup'ing fd %d to stderr: %v", f.Fd(), err) cmd.Fatalf("error dup'ing fd %d to stderr: %v", f.Fd(), err)
} }