-
Uncatchable exception?
Why would I not be able to catch an exception?
Specifically, when using the javax.xml.parsers.SAXParser package to open a URI with an invalid hostname (eg "www.w3.or" -- note the missing "g"), I get a java.net.UnknownHostException.
All well and good. But I can't catch it in the top-level invoking function. It travels right past my my catch (java.net.UnknownHostException uhe), past my catch( Throwable t ), past my main(), and the call stack is printed out by the VM (1.4.1_01, running under Win2K).
Any thoughts?
Michael
-
You've got your flow control wrong - it's perfectly catchable.
ArchAngel.
O:-)
-
Aha. Too much debugging code, not enough thought. I was doing a universal catch in an inner function, and then calling System.exit(). Not helpful.
Thanks for letting me bounce this off you.
Michael
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks