com.siyeh.ig.j2me.ConnectionResourceInspection.CloseVisitor uses "closeRecordStore" instead of "close", this way the inspection always reports false positives . Additionally even if "close" is checked, the following code:
will also report wrongly, because of the type cast. I know that this cast is unneccessary here, but it is just for demonstration. The real code is more like:
com.siyeh.ig.j2me.ConnectionResourceInspection.CloseVisitor uses "closeRecordStore" instead of "close", this way the inspection always reports false positives . Additionally even if "close" is checked, the following code:
will also report wrongly, because of the type cast. I know that this cast is unneccessary here, but it is just for demonstration. The real code is more like: