aboutsummaryrefslogtreecommitdiff
path: root/src/pkg/runtime/runtime.h
diff options
context:
space:
mode:
authorAkshat Kumar <seed@mail.nanosouffle.net>2013-03-08 00:54:44 +0100
committerRon Minnich <rminnich@gmail.com>2013-03-08 00:54:44 +0100
commita566deace1d96cd517e79227937e3036baca7ee2 (patch)
treea5973da40ca4bfcafd0f98a0284ac8c02d740270 /src/pkg/runtime/runtime.h
parent2ac799cfbcf212675d64ea0df835ca6c2e2aa368 (diff)
downloadgo-a566deace1d96cd517e79227937e3036baca7ee2.tar.xz
syscall: Plan 9: use lightweight errstr in entersyscall mode
Change 231af8ac63aa (CL 7314062) made runtime.enteryscall() set m->mcache = nil, which means that we can no longer use syscall.errstr in syscall.Syscall and syscall.Syscall6, since it requires a new buffer to be allocated for holding the error string. Instead, we use pre-allocated per-M storage to hold error strings from syscalls made while in entersyscall mode, and call runtime.findnull to calculate the lengths. Fixes #4994. R=rsc, rminnich, ality, dvyukov, rminnich, r CC=golang-dev https://golang.org/cl/7567043
Diffstat (limited to 'src/pkg/runtime/runtime.h')
-rw-r--r--src/pkg/runtime/runtime.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/pkg/runtime/runtime.h b/src/pkg/runtime/runtime.h
index e44064f1ae..66bcf603bd 100644
--- a/src/pkg/runtime/runtime.h
+++ b/src/pkg/runtime/runtime.h
@@ -320,6 +320,7 @@ struct M
#endif
#ifdef GOOS_plan9
int8* notesig;
+ byte* errstr;
#endif
SEH* seh;
uintptr end[];