try {
Image image = new Image("MyComputer/Documents/Photos/estambul.jpg");
try {
//...
image.print();
throw new NullPointerException();
} finally {
System.out.println("FINALLY");
image.close();
throw new IOException();
}
} catch (IOException ex){
System.out.println("IO_EXCEPTION");
System.out.println(ex.getMessage());
}
System.out.println("THREAD IS CONTINUE");
NullPointerException is not thrown here. However, there is no catch block that catches it. It looks like IOException is squashing NullPointerException. What is your comment? I did not understand.