зеркало из https://github.com/github/ruby.git
signal.c: discard SIGSYS
* signal.c (default_handler, Init_signal): discard SIGSYS, ENOSYS should raise a SystemCallError always instead. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51389 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
a894dc6a99
Коммит
38e62df9f6
|
@ -1,3 +1,8 @@
|
|||
Sun Jul 26 11:29:01 2015 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* signal.c (default_handler, Init_signal): discard SIGSYS, ENOSYS
|
||||
should raise a SystemCallError always instead.
|
||||
|
||||
Sun Jul 26 10:26:35 2015 Aaron Patterson <tenderlove@ruby-lang.org>
|
||||
|
||||
* ext/openssl/ossl_ssl.c (ossl_call_servername_cb): set the ssl context
|
||||
|
|
15
signal.c
15
signal.c
|
@ -935,6 +935,13 @@ check_reserved_signal_(const char *name, size_t name_len)
|
|||
}
|
||||
#endif
|
||||
|
||||
#ifdef SIGSYS
|
||||
static RETSIGTYPE
|
||||
sig_do_nothing(int sig)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
static void
|
||||
signal_exec(VALUE cmd, int safe, int sig)
|
||||
{
|
||||
|
@ -1061,6 +1068,11 @@ default_handler(int sig)
|
|||
case SIGPIPE:
|
||||
func = SIG_IGN;
|
||||
break;
|
||||
#endif
|
||||
#ifdef SIGSYS
|
||||
case SIGSYS:
|
||||
func = sig_do_nothing;
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
func = SIG_DFL;
|
||||
|
@ -1477,6 +1489,9 @@ Init_signal(void)
|
|||
#ifdef SIGPIPE
|
||||
install_sighandler(SIGPIPE, SIG_IGN);
|
||||
#endif
|
||||
#ifdef SIGSYS
|
||||
install_sighandler(SIGSYS, sig_do_nothing);
|
||||
#endif
|
||||
|
||||
#if defined(SIGCLD)
|
||||
init_sigchld(SIGCLD);
|
||||
|
|
Загрузка…
Ссылка в новой задаче