From f319cb1ad3062aaaa78a4da95e9ee90278d8ec33 Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Fri, 15 Nov 2002 19:04:36 +0000 Subject: [PATCH] * include/cygwin/version.h: Bump API_MINOR to accommodate below changes. * cygwin.din (siginterrupt): New export. * signal.cc (siginterrupt): New. --- winsup/cygwin/ChangeLog | 10 ++++++++++ winsup/cygwin/cygwin.din | 2 ++ winsup/cygwin/include/cygwin/version.h | 3 ++- winsup/cygwin/signal.cc | 13 +++++++++++++ 4 files changed, 27 insertions(+), 1 deletion(-) diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 3966a8575..bb713a058 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,13 @@ +2002-11-15 Christopher Faylor + + * include/cygwin/version.h: Bump API_MINOR to accommodate below + changes. + +002-11-14 Sergey Okhapkin + + * cygwin.din (siginterrupt): New export. + * signal.cc (siginterrupt): New. + 2002-11-15 Sergey Okhapkin * select.cc (peek_serial): Don't call PurgeComm() to avoid characters diff --git a/winsup/cygwin/cygwin.din b/winsup/cygwin/cygwin.din index 35789ab90..85418191b 100644 --- a/winsup/cygwin/cygwin.din +++ b/winsup/cygwin/cygwin.din @@ -740,6 +740,8 @@ sigemptyset _sigemptyset = sigemptyset sigfillset _sigfillset = sigfillset +siginterrupt +_siginterrupt = siginterrupt signal _signal = signal significand diff --git a/winsup/cygwin/include/cygwin/version.h b/winsup/cygwin/include/cygwin/version.h index f0caae10c..a58cbddfa 100644 --- a/winsup/cygwin/include/cygwin/version.h +++ b/winsup/cygwin/include/cygwin/version.h @@ -162,12 +162,13 @@ details. */ 62: Erroneously bumped. 63: Export pututline. 64: Export fseeko, ftello + 65: Export fseeko, ftello */ /* Note that we forgot to bump the api for ualarm, strtoll, strtoull */ #define CYGWIN_VERSION_API_MAJOR 0 -#define CYGWIN_VERSION_API_MINOR 64 +#define CYGWIN_VERSION_API_MINOR 65 /* There is also a compatibity version number associated with the shared memory regions. It is incremented when incompatible diff --git a/winsup/cygwin/signal.cc b/winsup/cygwin/signal.cc index 382a8a2ec..9c807f4ef 100644 --- a/winsup/cygwin/signal.cc +++ b/winsup/cygwin/signal.cc @@ -407,3 +407,16 @@ pause (void) { return handle_sigsuspend (myself->getsigmask ()); } + +extern "C" int +siginterrupt (int sig, int flag) +{ + struct sigaction act; + (void)sigaction(sig, NULL, &act); + if (flag) + act.sa_flags &= ~SA_RESTART; + else + act.sa_flags |= SA_RESTART; + return sigaction(sig, &act, NULL); +} +