]> Cypherpunks repositories - gostls13.git/commit
runtime: Update open/close/read/write to return -1 on error.
authorKeith Randall <khr@golang.org>
Tue, 3 Mar 2015 04:16:48 +0000 (20:16 -0800)
committerKeith Randall <khr@golang.org>
Tue, 3 Mar 2015 17:46:36 +0000 (17:46 +0000)
commitf584c05fcc38fef1582681a7e2841b725f0a827d
tree5a96b88327f816c5e32b57090382df4b10793153
parent74e88dfdeebef392d52d3f792e2071b058c1e231
runtime: Update open/close/read/write to return -1 on error.

Error detection code copied from syscall, where presumably
we actually do it right.

Note that we throw the errno away.  The runtime doesn't use it.

Fixes #10052

Change-Id: I8de77dda6bf287276b137646c26b84fa61554ec8
Reviewed-on: https://go-review.googlesource.com/6571
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Russ Cox <rsc@golang.org>
21 files changed:
src/runtime/export_test.go
src/runtime/os_nacl.go
src/runtime/os_windows.go
src/runtime/runtime_test.go
src/runtime/sys_darwin_386.s
src/runtime/sys_darwin_amd64.s
src/runtime/sys_darwin_arm.s
src/runtime/sys_dragonfly_386.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_ppc64x.s
src/runtime/sys_netbsd_386.s
src/runtime/sys_netbsd_amd64.s
src/runtime/sys_netbsd_arm.s
src/runtime/sys_openbsd_386.s
src/runtime/sys_openbsd_amd64.s