summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2010-06-29 17:47:27 -0700
committerRuss Cox <rsc@golang.org>2010-06-29 17:47:27 -0700
commit2de9ec86e32239ca4e32fc26aa291a144bfaca3d (patch)
treecd027bf61ad1e4c60473046a819f0801e22a2cc5 /src
parent71d167578884a06b134c3c629a17dc883e024439 (diff)
downloadgolang-2de9ec86e32239ca4e32fc26aa291a144bfaca3d.tar.gz
runtime: fix scheduling bug - world wasn't stopping
Fixes issue 886. R=r CC=golang-dev http://codereview.appspot.com/1667051
Diffstat (limited to 'src')
-rw-r--r--src/pkg/runtime/proc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pkg/runtime/proc.c b/src/pkg/runtime/proc.c
index a587a7fd4..2abb28307 100644
--- a/src/pkg/runtime/proc.c
+++ b/src/pkg/runtime/proc.c
@@ -168,7 +168,7 @@ gput(G *g)
M *m;
// If g is wired, hand it off directly.
- if((m = g->lockedm) != nil) {
+ if(sched.mcpu < sched.mcpumax && (m = g->lockedm) != nil) {
mnextg(m, g);
return;
}