SUGGESTED FIX
A fix for this should be incorporated into 1.4.1 and 1.4.2.
My apologies for creating this bug in 1.4.1. This was fixed in
1.5.0 as part of 4840909 - Solaris 10 changes to support SIGJVM1,
SIGJVM2. Credit for the fix goes to Dave Dice who caught this
during his code review.
The problem is that the unblocked signal set (unblocked_sigs)
is initialized in signal_sets_init() using the default value
of os::Solaris::SIGinterrupt() before install_signal_handlers()
is called where the check is made for UseAltSigs. This bug
also applies to os::Solaris::SIGasync() and should be fixed
for that as well.
If you want the entire fix, i.e. the Solaris 10 fix to no
longer use SIGUSR1 even without the UseAltSigs flag, then
you can take the entire set of changes from 4840909 putback in April 2003
to the 1.5.0 tree. This includes:
jvm_solaris.h 1.15 fix comment
os_solaris.cpp 1.263.5.1 key changes
os_solaris.hpp 1.77.3.1 Add signal_sets_init to Solaris class so it can call
set_SIGinterrupt etc.
If you want to minimize the changes you make, you can
skip jvm_solaris.h comment changes. You need the os_solaris.hpp
changes. And you can extract the non-Solaris 10 improvements
from os_solaris.cpp:
1. in signal_sets_init: change
sigaddset(&unblocked_sigs, os::Solaris::SIGinterrupt());
sigaddset(&unblocked_sigs, os::Solaris::SIGasync());
to
if (UseAltSigs) {
os::Solaris::set_SIGinterrupt(ALT_INTERRUPT_SIGNAL);
os::Solaris::set_SIGasync(ALT_ASYNC_SIGNAL);
} else {
os::Solaris::set_SIGinterrupt(INTERRUPT_SIGNAL);
os::Solaris::set_SIGasync(ASYNC_SIGNAL);
}
2. in install_signal_handlers change:
if (UseAltSigs) {
os::Solaris::set_SIGinterrupt(ALT_INTERRUPT_SIGNAL);
os::Solaris::set_SIGasync(ALT_ASYNC_SIGNAL);
// Pre-1.4.1 Libjsig limited to signal chaining signals <= 32 so
// can not register overridable signals which might be > 32
if (libjsig_is_loaded && libjsigversion <= JSIG_VERSION_1_4_1) {
// Tell libjsig jvm has finished setting signal handlers
(*end_signal_setting)();
libjsigdone = true;
}
}
to
if (os::Solaris::SIGinterrupt() > OLDMAXSIGNUM || os::Solaris::SIGasync() > OL
DMAXSIGNUM) {
// Pre-1.4.1 Libjsig limited to signal chaining signals <= 32 so
// can not register overridable signals which might be > 32
if (libjsig_is_loaded && libjsigversion <= JSIG_VERSION_1_4_1) {
// Tell libjsig jvm has finished setting signal handlers
(*end_signal_setting)();
libjsigdone = true;
}
}
My recommendation, since 1.4.2 is the default version shipping
for Solaris 10, is to take the entire set of changes.
###@###.### 2003-11-17