java/RAII/src/cz/frantovo/priklady/raii/Zdroj.java
changeset 25 95be94124ce9
parent 21 627912dacae3
     1.1 --- a/java/RAII/src/cz/frantovo/priklady/raii/Zdroj.java	Tue Sep 09 16:01:58 2014 +0200
     1.2 +++ b/java/RAII/src/cz/frantovo/priklady/raii/Zdroj.java	Tue Sep 09 16:18:47 2014 +0200
     1.3 @@ -59,7 +59,11 @@
     1.4  
     1.5  	@Override
     1.6  	protected void finalize() throws Throwable {
     1.7 -		System.err.println("Finalizujeme: " + this);
     1.8 +		try {
     1.9 +			System.err.println("Finalizujeme: " + this);
    1.10 +		} finally {
    1.11 +			super.finalize();
    1.12 +		}
    1.13  	}
    1.14  
    1.15  	@Override