]> Cypherpunks repositories - gostls13.git/commit
runtime: report correct fcntl syscall error in checkCloseonexec
authorTobias Klauser <tklauser@distanz.ch>
Wed, 17 May 2023 07:38:20 +0000 (09:38 +0200)
committerGopher Robot <gobot@golang.org>
Fri, 19 May 2023 13:50:58 +0000 (13:50 +0000)
commit9ed2b115fb405bf730772d0e825876d85deb7340
tree5da909bc3c391f70438f7de0f66427da365b080a
parent08e39a196186b0b2ce852a156515001b8de190dc
runtime: report correct fcntl syscall error in checkCloseonexec

runtime.fcntl returns the error value as a negative value, so it needs
to be inverted before being converted to syscall.Errno.

Change-Id: I43cd0b035150424ac59e623b17a9396c7d62c186
Reviewed-on: https://go-review.googlesource.com/c/go/+/495675
TryBot-Result: Gopher Robot <gobot@golang.org>
Auto-Submit: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
src/runtime/nbpipe_test.go