Avoid re-entry in the cleanup signal handlers.
This commit is contained in:
parent
f2aa877507
commit
77b4aabadd
|
@ -350,6 +350,10 @@ main_cleanup (sig)
|
||||||
#ifndef DONT_USE_SIGNALS
|
#ifndef DONT_USE_SIGNALS
|
||||||
const char *name;
|
const char *name;
|
||||||
char temp[10];
|
char temp[10];
|
||||||
|
static int reenter = 0;
|
||||||
|
|
||||||
|
if (reenter++)
|
||||||
|
_exit(1);
|
||||||
|
|
||||||
switch (sig)
|
switch (sig)
|
||||||
{
|
{
|
||||||
|
|
|
@ -771,6 +771,11 @@ patch_dirproc (callerdat, dir, repos, update_dir, entries)
|
||||||
static RETSIGTYPE
|
static RETSIGTYPE
|
||||||
patch_cleanup ()
|
patch_cleanup ()
|
||||||
{
|
{
|
||||||
|
static int reenter = 0;
|
||||||
|
|
||||||
|
if (reenter++)
|
||||||
|
_exit(1);
|
||||||
|
|
||||||
/* Note that the checks for existence_error are because we are
|
/* Note that the checks for existence_error are because we are
|
||||||
called from a signal handler, without SIG_begincrsect, so
|
called from a signal handler, without SIG_begincrsect, so
|
||||||
we don't know whether the files got created. */
|
we don't know whether the files got created. */
|
||||||
|
|
|
@ -8238,6 +8238,10 @@ count_delta_actions (np, ignore)
|
||||||
RETSIGTYPE
|
RETSIGTYPE
|
||||||
rcs_cleanup ()
|
rcs_cleanup ()
|
||||||
{
|
{
|
||||||
|
static int reenter = 0;
|
||||||
|
|
||||||
|
if (reenter++)
|
||||||
|
_exit(1);
|
||||||
/* Note that the checks for existence_error are because we are
|
/* Note that the checks for existence_error are because we are
|
||||||
called from a signal handler, so we don't know whether the
|
called from a signal handler, so we don't know whether the
|
||||||
files got created. */
|
files got created. */
|
||||||
|
|
Loading…
Reference in New Issue