Details
-
Bug
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
2.5.1
-
None
-
Reviewed
Description
String lastLine = null; int errCode = -1; try { while ((line = input.readLine()) != null) { ... if (lastLine.endsWith(NamenodeFsck.HEALTHY_STATUS)) { errCode = 0;
If the input stream is empty, lastLine is kept null, leading to NPE.