Community
Participate
Working Groups
In the mentioned method the input stream 'in' is closed in the finally block, and any exceptions catched. It can be that 'in' is null, which raises a NullPointerException. Of course this one is catched by the empty catch block, but I think this situation should be proven explicitly. I have usually an exception breakpoint on NullPointerException on when debugging code, and I usually expect NPEs only in the code that I want to debug. So please make this a bit more safer: =============================== try { f.close(); } catch (Exception e) { } try { in.close(); } catch (Exception e) { =============================== Replace by: try { if (f!=null) f.close(); } catch (Exception e) { } try { if (in!=null) in.close(); } catch (Exception e) {
In this case, 'f' will never be null. However, 'in' could end up being null, so I have added the null check. Thanks for reporting this. Fixed in HEAD. See ExternalModelManager.java
Surely this should be in SR1?
See bug 353814 for 3.7.1 inclusion
Verified code is in I20110802-2000