Skip to content

Commit

Permalink
Revert "Fix SIGALRM core dump (Solaris patch 230-18229654)"
Browse files Browse the repository at this point in the history
This reverts commit 13e7b26. It caused the regression test for the
'alarm' builtin, introduced in 18b3f4a, to hang on FreeBSD.
  • Loading branch information
McDutchie committed Jan 9, 2021
1 parent 7d2bb8f commit 4d0b77d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
2 changes: 1 addition & 1 deletion src/cmd/ksh93/bltins/alarm.c
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ static void trap_timeout(void* handle)
tp->timeout = 0;
tp->flags |= L_FLAG;
tp->sh->sigflag[SIGALRM] |= SH_SIGALRM;
if(sh_isstate(SH_TTYWAIT) && !tp->sh->bltinfun)
if(sh_isstate(SH_TTYWAIT))
sh_timetraps(tp->sh);
}

Expand Down
5 changes: 0 additions & 5 deletions src/cmd/ksh93/sh/xec.c
Original file line number Diff line number Diff line change
Expand Up @@ -2643,11 +2643,6 @@ int sh_exec(register const Shnode_t *t, int flags)
break;
}
}
if(shp->trapnote&SH_SIGALRM)
{
shp->trapnote &= ~SH_SIGALRM;
sh_timetraps(shp);
}
if(shp->trapnote || (shp->exitval && sh_isstate(SH_ERREXIT)) &&
t && echeck)
sh_chktrap(shp);
Expand Down

0 comments on commit 4d0b77d

Please sign in to comment.