This rule is Obsolete | |
Synopsis: | Avoid empty catch blocks |
Language: | Java |
Severity Level: | 1 |
Category: | Basic |
Description: |
Empty Catch Block finds instances where an exception is caught,
but nothing is done. In most circumstances, this swallows an exception
which should either be acted on or reported.public void doSomething() { try { FileInputStream fis = new FileInputStream("/tmp/bugger"); } catch (IOException ioe) { // not good } } |