/* Xt features made by Fred Pierresteguy. */
#include <config.h>
-#include <signal.h>
#include <stdio.h>
#include <setjmp.h>
#include "lisp.h"
#include "blockinput.h"
-
-/* Need syssignal.h for various externs and definitions that may be required
- by some configurations for calls to signal later in this source file. */
#include "syssignal.h"
/* This may include sys/types.h, and that somehow loses
XSetClipMask (next->display, next->gc, None);
next->hl = save;
next->num_clips = 0;
+ next->clip_head = s->next;
}
}
}
#ifdef USG
/* USG systems forget handlers when they are used;
must reestablish each time */
- signal (signalnum, x_connection_signal);
+ struct sigaction action;
+ emacs_sigaction_init (&action, x_connection_signal);
+ sigaction (signalnum, &action, 0);
#endif /* USG */
}
}
/* Ordinary stack unwind doesn't deal with these. */
+ {
+ sigset_t unblocked;
+ sigemptyset (&unblocked);
#ifdef SIGIO
- sigunblock (sigmask (SIGIO));
+ sigaddset (&unblocked, SIGIO);
#endif
- sigunblock (sigmask (SIGALRM));
+ sigaddset (&unblocked, SIGALRM);
+ pthread_sigmask (SIG_UNBLOCK, &unblocked, 0);
+ }
TOTALLY_UNBLOCK_INPUT;
unbind_to (idx, Qnil);
void
x_initialize (void)
{
+ struct sigaction action;
+
baud_rate = 19200;
x_noop_count = 0;
XSetErrorHandler (x_error_handler);
XSetIOErrorHandler (x_io_error_quitter);
- signal (SIGPIPE, x_connection_signal);
+ emacs_sigaction_init (&action, x_connection_signal);
+ sigaction (SIGPIPE, &action, 0);
}