Commit 6a6a4abb by Anthony Green

Check for sigaction.

From-SVN: r42790
parent 46d7fc96
...@@ -409,7 +409,7 @@ else ...@@ -409,7 +409,7 @@ else
AC_CHECK_FUNCS(iconv nl_langinfo setlocale) AC_CHECK_FUNCS(iconv nl_langinfo setlocale)
AC_CHECK_FUNCS(inet_aton inet_addr, break) AC_CHECK_FUNCS(inet_aton inet_addr, break)
AC_CHECK_FUNCS(inet_pton uname inet_ntoa) AC_CHECK_FUNCS(inet_pton uname inet_ntoa)
AC_CHECK_FUNCS(backtrace fork execvp pipe) AC_CHECK_FUNCS(backtrace fork execvp pipe sigaction)
AC_CHECK_HEADERS(execinfo.h unistd.h dlfcn.h) AC_CHECK_HEADERS(execinfo.h unistd.h dlfcn.h)
AC_CHECK_LIB(dl, dladdr, [ AC_CHECK_LIB(dl, dladdr, [
AC_DEFINE(HAVE_DLADDR)]) AC_DEFINE(HAVE_DLADDR)])
......
...@@ -269,6 +269,9 @@ ...@@ -269,6 +269,9 @@
/* Define if you have the setlocale function. */ /* Define if you have the setlocale function. */
#undef HAVE_SETLOCALE #undef HAVE_SETLOCALE
/* Define if you have the sigaction function. */
#undef HAVE_SIGACTION
/* Define if you have the sleep function. */ /* Define if you have the sleep function. */
#undef HAVE_SLEEP #undef HAVE_SLEEP
......
...@@ -877,14 +877,16 @@ _Jv_CreateJavaVM (void* /*vm_args*/) ...@@ -877,14 +877,16 @@ _Jv_CreateJavaVM (void* /*vm_args*/)
#ifdef USE_WIN32_SIGNALLING #ifdef USE_WIN32_SIGNALLING
// Install exception handler // Install exception handler
SetUnhandledExceptionFilter (win32_exception_handler); SetUnhandledExceptionFilter (win32_exception_handler);
#else #elif defined(HAVE_SIGACTION)
// We only want this on POSIX systems. // We only want this on POSIX systems.
struct sigaction act; struct sigaction act;
act.sa_handler = SIG_IGN; act.sa_handler = SIG_IGN;
sigemptyset (&act.sa_mask); sigemptyset (&act.sa_mask);
act.sa_flags = 0; act.sa_flags = 0;
sigaction (SIGPIPE, &act, NULL); sigaction (SIGPIPE, &act, NULL);
#endif /* USE_WIN32_SIGNALLING */ #else
signal (SIGPIPE, SIG_IGN);
#endif
_Jv_JNI_Init (); _Jv_JNI_Init ();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment