public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* java/8980: NullPointerException not being caught by exception handler
@ 2002-12-17 6:06 sergio-s-freire
0 siblings, 0 replies; only message in thread
From: sergio-s-freire @ 2002-12-17 6:06 UTC (permalink / raw)
To: gcc-gnats
>Number: 8980
>Category: java
>Synopsis: NullPointerException not being caught by exception handler
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Dec 17 06:06:02 PST 2002
>Closed-Date:
>Last-Modified:
>Originator: sergio-s-freire@ptinovacao.pt
>Release: gcc-3.2
>Organization:
>Environment:
i386-redhat-linux (RedHat Linux 8.0, Intel Pentium III)
>Description:
NullPointerException is not being caught correctly in the
following code. Output is 'Exception in thread "main"' instead of 'Works
fine'.
public class Foo {
public static void main(String[] args) {
Object nada = null;
try {
nada.toString();
} catch (Throwable t) {
System.out.println("Works fine");
}
}
}
>How-To-Repeat:
gcj -c Foo.java && ./a.out
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2002-12-17 14:06 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-12-17 6:06 java/8980: NullPointerException not being caught by exception handler sergio-s-freire
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).