]> Cypherpunks repositories - gostls13.git/commit
runtime: change read and write to return negative errno value
authorIan Lance Taylor <iant@golang.org>
Fri, 5 Apr 2019 18:42:37 +0000 (11:42 -0700)
committerIan Lance Taylor <iant@golang.org>
Mon, 21 Oct 2019 14:07:34 +0000 (14:07 +0000)
commitb653c878b1ad8d1b4f8d7b04201d0cb0a4156ead
tree3f4189ae0a4f5c61ae8fc0badf402d2016533289
parent6917b3c839af615e22ef479b23983d186e578bd6
runtime: change read and write to return negative errno value

The internal read and write functions used to return -1 on error;
change them to return a negative errno value instead.
This will be used by later CLs in this series.

For most targets this is a simplification, although for ones that call
into libc it is a complication.

Updates #27707

Change-Id: Id02bf9487f03e7e88e4f2b85e899e986738697ad
Reviewed-on: https://go-review.googlesource.com/c/go/+/171823
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
30 files changed:
src/runtime/crash_unix_test.go
src/runtime/os2_aix.go
src/runtime/os3_solaris.go
src/runtime/os_solaris.go
src/runtime/runtime_test.go
src/runtime/stubs2.go
src/runtime/sys_darwin_386.s
src/runtime/sys_darwin_amd64.s
src/runtime/sys_darwin_arm.s
src/runtime/sys_darwin_arm64.s
src/runtime/sys_dragonfly_amd64.s
src/runtime/sys_freebsd_386.s
src/runtime/sys_freebsd_amd64.s
src/runtime/sys_freebsd_arm.s
src/runtime/sys_linux_386.s
src/runtime/sys_linux_amd64.s
src/runtime/sys_linux_arm.s
src/runtime/sys_linux_arm64.s
src/runtime/sys_linux_mips64x.s
src/runtime/sys_linux_mipsx.s
src/runtime/sys_linux_ppc64x.s
src/runtime/sys_linux_s390x.s
src/runtime/sys_netbsd_386.s
src/runtime/sys_netbsd_amd64.s
src/runtime/sys_netbsd_arm.s
src/runtime/sys_netbsd_arm64.s
src/runtime/sys_openbsd_386.s
src/runtime/sys_openbsd_amd64.s
src/runtime/sys_openbsd_arm.s
src/runtime/sys_openbsd_arm64.s