This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Java in General and the fly likes Null pointer before finally block Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Null pointer before finally block" Watch "Null pointer before finally block" New topic
Author

Null pointer before finally block

Santosh Kumar Nayak
Ranch Hand

Joined: Aug 02, 2011
Posts: 92
If there is a NULL Pointer Exception before FINALLY BLOCK then will the finally block get executed ?
Stephan van Hulst
Bartender

Joined: Sep 20, 2010
Posts: 3602
    
  14

Did you read the Oracle tutorial on the finally-block?

http://docs.oracle.com/javase/tutorial/essential/exceptions/finally.html
Santosh Kumar Nayak
Ranch Hand

Joined: Aug 02, 2011
Posts: 92
Thank you for the useful link
 
Consider Paul's rocket mass heater.
 
subject: Null pointer before finally block
 
Similar Threads
Error in datasource using SQLSERVER
Null Pointer Exception @ SessionFactory
Problem with the sample hibernate program
java.lang.NullPtrEx
how to close connection object in finally block when an exception is raised in try bl