diff options
Diffstat (limited to 'src/runtime/os_linux.go')
| -rw-r--r-- | src/runtime/os_linux.go | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/src/runtime/os_linux.go b/src/runtime/os_linux.go index bc0d9f2027..92c3db8616 100644 --- a/src/runtime/os_linux.go +++ b/src/runtime/os_linux.go @@ -257,22 +257,10 @@ func gettid() uint32 // Called to initialize a new m (including the bootstrap m). // Called on the new thread, cannot allocate memory. func minit() { - // Initialize signal handling. - _g_ := getg() - - minitSignalStack() + minitSignals() // for debuggers, in case cgo created the thread - _g_.m.procid = uint64(gettid()) - - // restore signal mask from m.sigmask and unblock essential signals - nmask := _g_.m.sigmask - for i := range sigtable { - if sigtable[i].flags&_SigUnblock != 0 { - sigdelset(&nmask, i) - } - } - sigprocmask(_SIG_SETMASK, &nmask, nil) + getg().m.procid = uint64(gettid()) } // Called from dropm to undo the effect of an minit. |
