diff options
| author | Dmitriy Vyukov <dvyukov@google.com> | 2013-02-20 21:17:56 +0400 |
|---|---|---|
| committer | Dmitriy Vyukov <dvyukov@google.com> | 2013-02-20 21:17:56 +0400 |
| commit | 1e063eea38fe3ecc8bea4e35bc0482fa8100ea80 (patch) | |
| tree | 93b6ea8af7657cfa5ee1c41bee5cae12c0a5dd69 /src/pkg/runtime/panic.c | |
| parent | e25f19a638835d129545a82e559c2fb621b48e0c (diff) | |
| download | go-1e063eea38fe3ecc8bea4e35bc0482fa8100ea80.tar.xz | |
runtime: prepare for M's running w/o mcache
Can not happen ATM. In preparation for the new scheduler.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/7388043
Diffstat (limited to 'src/pkg/runtime/panic.c')
| -rw-r--r-- | src/pkg/runtime/panic.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/pkg/runtime/panic.c b/src/pkg/runtime/panic.c index a0651e4ad5..603ff62eb3 100644 --- a/src/pkg/runtime/panic.c +++ b/src/pkg/runtime/panic.c @@ -382,6 +382,8 @@ nomatch: void runtime·startpanic(void) { + if(m->mcache == nil) // can happen if called from signal handler or throw + m->mcache = runtime·allocmcache(); if(m->dying) { runtime·printf("panic during panic\n"); runtime·exit(3); |
