You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Ted Yu (JIRA)" <ji...@apache.org> on 2014/09/19 22:02:34 UTC
[jira] [Created] (HDFS-7101) Potential null dereference in
DFSck#doWork()
Ted Yu created HDFS-7101:
----------------------------
Summary: Potential null dereference in DFSck#doWork()
Key: HDFS-7101
URL: https://issues.apache.org/jira/browse/HDFS-7101
Project: Hadoop HDFS
Issue Type: Bug
Reporter: Ted Yu
Priority: Minor
{code}
String lastLine = null;
int errCode = -1;
try {
while ((line = input.readLine()) != null) {
...
if (lastLine.endsWith(NamenodeFsck.HEALTHY_STATUS)) {
errCode = 0;
{code}
If readLine() throws exception, lastLine may be null, leading to NPE.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)