United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-7193463 Terminator.setup should ignore IAE when registering signal handlers
JDK-7193463 : Terminator.setup should ignore IAE when registering signal handlers

Details
Type:
Bug
Submit Date:
2012-08-23
Status:
Closed
Updated Date:
2012-11-08
Project Name:
JDK
Resolved Date:
2012-09-05
Component:
core-libs
OS:
generic,windows_7
Sub-Component:
java.lang
CPU:
x86,generic
Priority:
P5
Resolution:
Fixed
Affected Versions:
7,8
Fixed Versions:

Related Reports
Backport:
Duplicate:

Sub Tasks

Description
FULL PRODUCT VERSION :


A DESCRIPTION OF THE PROBLEM :
In java.lang.Terminator, separate signal registrations wrapped in a single try block to dedicated try block.

Current code below:
        try {
            Signal.handle(new Signal("INT"), sh);
            Signal.handle(new Signal("TERM"), sh);
        } catch (IllegalArgumentException e) {
        }
The revised code below:
        try {
            Signal.handle(new Signal("INT"), sh);
        } catch (IllegalArgumentException e) {
        }
        try {
            Signal.handle(new Signal("TERM"), sh);
        } catch (IllegalArgumentException e) {
        }
The improved version makes more sense since exception thrown from first Signal.handle call does not affect subsequent calls. This is more consistent with its original intention.

See more detailed discussion in community @
http://mail.openjdk.java.net/pipermail/core-libs-dev/2012-August/011189.html



REPRODUCIBILITY :
This bug can be reproduced always.

                                    

Comments
EVALUATION

http://hg.openjdk.java.net/jdk8/tl/jdk/rev/e7b53fe85540
                                     
2012-08-23
close it with verified in b61 as it is a trivial fix. 
                                     
2012-11-08



Hardware and Software, Engineered to Work Together