summaryrefslogtreecommitdiff
path: root/src/runtime/rdebug.go
blob: f2766d7937e10120d99852723ec95e0eb75d2c44 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// Copyright 2014 The Go Authors.  All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package runtime

func setMaxStack(in int) (out int) {
	out = int(maxstacksize)
	maxstacksize = uintptr(in)
	return out
}

func setPanicOnFault(new bool) (old bool) {
	mp := acquirem()
	old = mp.curg.paniconfault
	mp.curg.paniconfault = new
	releasem(mp)
	return old
}