aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/stack.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/stack.go')
-rw-r--r--src/runtime/stack.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/runtime/stack.go b/src/runtime/stack.go
index 4b647976f0..a338708d76 100644
--- a/src/runtime/stack.go
+++ b/src/runtime/stack.go
@@ -1115,6 +1115,9 @@ func newstack() {
shrinkstack(gp)
}
+ // Set a flag indicated that we've been synchronously preempted.
+ gp.syncSafePoint = true
+
if gp.preemptStop {
preemptPark(gp) // never returns
}