Re: [RFC] Don't immediately SIGTERM the child of "target remote |".

Eli Zaretskii
2011-11-24T03:57:51Z

> Date: Wed, 23 Nov 2011 16:00:51 -0800 (PST)
> From: dje@google.com (Doug Evans)
>
> +#if defined (HAVE_SIGACTION) && defined (SA_RESTART)
> + {
> + struct sigaction sa, osa;
> + sa.sa_handler = sigalrm_handler;
> + sigemptyset (&sa.sa_mask);
> + sa.sa_flags = 0;
> + sigaction (SIGALRM, &sa, &osa);
> + ofunc = osa.sa_handler;
> + }
> +#else
> + ofunc = (void (*)()) signal (SIGALRM, sigalrm_handler);
> +#endif

SIGALRM may not be defined (e.g., on MS-Windows).