mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-04 15:41:21 +08:00
runtime: Ignore SIGPROF if not on a Go thread.
From-SVN: r201154
This commit is contained in:
parent
433cc7b037
commit
5f9ae7f2d6
@ -166,21 +166,22 @@ runtime_sighandler (int sig, Siginfo *info,
|
||||
int i;
|
||||
|
||||
m = runtime_m ();
|
||||
|
||||
#ifdef SIGPROF
|
||||
if (sig == SIGPROF)
|
||||
{
|
||||
if (m != NULL && gp != m->g0 && gp != m->gsignal)
|
||||
runtime_sigprof ();
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (m == NULL)
|
||||
{
|
||||
runtime_badsignal (sig);
|
||||
return;
|
||||
}
|
||||
|
||||
#ifdef SIGPROF
|
||||
if (sig == SIGPROF)
|
||||
{
|
||||
if (gp != runtime_m ()->g0 && gp != runtime_m ()->gsignal)
|
||||
runtime_sigprof ();
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
for (i = 0; runtime_sigtab[i].sig != -1; ++i)
|
||||
{
|
||||
SigTab *t;
|
||||
|
Loading…
x
Reference in New Issue
Block a user