summaryrefslogtreecommitdiff
path: root/libjava/prims.cc
diff options
context:
space:
mode:
authorbothner <bothner@138bc75d-0d04-0410-961f-82ee72b054a4>2004-09-26 20:38:49 +0000
committerbothner <bothner@138bc75d-0d04-0410-961f-82ee72b054a4>2004-09-26 20:38:49 +0000
commit6710c7a1caf4f6815eb5b477753458eaa85daa15 (patch)
treef3d8f4582e3394453fefaf9adb132057dab7f3a8 /libjava/prims.cc
parentb2d590d16b6e4d5a8a166c2d839c459e3990664e (diff)
downloadgcc-6710c7a1caf4f6815eb5b477753458eaa85daa15.tar.gz
* prims.cc (unblock_signal): Annotate signum with __unused__ to
avoid warnings in the non-POSIX_VERSION case. Also, we only need this function if either HANDLE_SEGV or HANDLE_FPE, so place it inside an #if block. * include/default-signal.h (SIGNAL_HANDLER): Parameters are __unused__. * include/i386-signal.h (SIGNAL_HANDLER): Likewise * include/mips-signal.h (SIGNAL_HANDLER): Likewise * include/sparc-signal.h (SIGNAL_HANDLER): Likewise git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@88148 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/prims.cc')
-rw-r--r--libjava/prims.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/libjava/prims.cc b/libjava/prims.cc
index 7511906b19a..70ede2765cb 100644
--- a/libjava/prims.cc
+++ b/libjava/prims.cc
@@ -125,10 +125,11 @@ void (*_Jv_JVMPI_Notify_THREAD_END) (JVMPI_Event *event);
#endif
+#if defined (HANDLE_SEGV) || defined(HANDLE_FPE)
/* Unblock a signal. Unless we do this, the signal may only be sent
once. */
static void
-unblock_signal (int signum)
+unblock_signal (int signum __attribute__ ((__unused__)))
{
#ifdef _POSIX_VERSION
sigset_t sigs;
@@ -138,6 +139,7 @@ unblock_signal (int signum)
sigprocmask (SIG_UNBLOCK, &sigs, NULL);
#endif
}
+#endif
#ifdef HANDLE_SEGV
SIGNAL_HANDLER (catch_segv)