[jira] [Updated] (HDFS-7101) Potential null dereference in DFSck#doWork()
[ https://issues.apache.org/jira/browse/HDFS-7101?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Akira Ajisaka updated HDFS-7101: Resolution: Fixed Hadoop Flags: Reviewed Fix Version/s: 2.9.2 3.1.1 3.2.0 2.10.0 Status: Resolved (was: Patch Available) Committed this to trunk. Thanks [~rsk13th] and [~yuzhih...@gmail.com] for the contribution. > Potential null dereference in DFSck#doWork() > > > Key: HDFS-7101 > URL: https://issues.apache.org/jira/browse/HDFS-7101 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.5.1 >Reporter: Ted Yu >Assignee: skrho >Priority: Minor > Labels: BB2015-05-TBR > Fix For: 2.10.0, 3.2.0, 3.1.1, 2.9.2 > > Attachments: HDFS-7101.v1.patch, HDFS-7101_001.patch > > > {code} > String lastLine = null; > int errCode = -1; > try { > while ((line = input.readLine()) != null) { > ... > if (lastLine.endsWith(NamenodeFsck.HEALTHY_STATUS)) { > errCode = 0; > {code} > If the input stream is empty, lastLine is kept null, leading to NPE. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org
[jira] [Updated] (HDFS-7101) Potential null dereference in DFSck#doWork()
[ https://issues.apache.org/jira/browse/HDFS-7101?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Akira Ajisaka updated HDFS-7101: Description: {code} String lastLine = null; int errCode = -1; try { while ((line = input.readLine()) != null) { ... if (lastLine.endsWith(NamenodeFsck.HEALTHY_STATUS)) { errCode = 0; {code} If the input stream is empty, lastLine is kept null, leading to NPE. was: {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. > Potential null dereference in DFSck#doWork() > > > Key: HDFS-7101 > URL: https://issues.apache.org/jira/browse/HDFS-7101 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.5.1 >Reporter: Ted Yu >Assignee: skrho >Priority: Minor > Labels: BB2015-05-TBR > Attachments: HDFS-7101.v1.patch, HDFS-7101_001.patch > > > {code} > String lastLine = null; > int errCode = -1; > try { > while ((line = input.readLine()) != null) { > ... > if (lastLine.endsWith(NamenodeFsck.HEALTHY_STATUS)) { > errCode = 0; > {code} > If the input stream is empty, lastLine is kept null, leading to NPE. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org
[jira] [Updated] (HDFS-7101) Potential null dereference in DFSck#doWork()
[ https://issues.apache.org/jira/browse/HDFS-7101?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ted Yu updated HDFS-7101: - Attachment: HDFS-7101.v1.patch > Potential null dereference in DFSck#doWork() > > > Key: HDFS-7101 > URL: https://issues.apache.org/jira/browse/HDFS-7101 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.5.1 >Reporter: Ted Yu >Assignee: skrho >Priority: Minor > Labels: BB2015-05-TBR > Attachments: HDFS-7101.v1.patch, HDFS-7101_001.patch > > > {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)
[jira] [Updated] (HDFS-7101) Potential null dereference in DFSck#doWork()
[ https://issues.apache.org/jira/browse/HDFS-7101?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ted Yu updated HDFS-7101: - Description: {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. was: {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. > Potential null dereference in DFSck#doWork() > > > Key: HDFS-7101 > URL: https://issues.apache.org/jira/browse/HDFS-7101 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.5.1 >Reporter: Ted Yu >Assignee: skrho >Priority: Minor > Labels: BB2015-05-TBR > Attachments: HDFS-7101_001.patch > > > {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)
[jira] [Updated] (HDFS-7101) Potential null dereference in DFSck#doWork()
[ https://issues.apache.org/jira/browse/HDFS-7101?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ted Yu updated HDFS-7101: - Description: {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. was: {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. > Potential null dereference in DFSck#doWork() > > > Key: HDFS-7101 > URL: https://issues.apache.org/jira/browse/HDFS-7101 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.5.1 >Reporter: Ted Yu >Assignee: skrho >Priority: Minor > Labels: BB2015-05-TBR > Attachments: HDFS-7101_001.patch > > > {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)
[jira] [Updated] (HDFS-7101) Potential null dereference in DFSck#doWork()
[ https://issues.apache.org/jira/browse/HDFS-7101?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Allen Wittenauer updated HDFS-7101: --- Labels: BB2015-05-TBR (was: ) > Potential null dereference in DFSck#doWork() > > > Key: HDFS-7101 > URL: https://issues.apache.org/jira/browse/HDFS-7101 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.5.1 >Reporter: Ted Yu >Assignee: skrho >Priority: Minor > Labels: BB2015-05-TBR > Attachments: HDFS-7101_001.patch > > > {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)
[jira] [Updated] (HDFS-7101) Potential null dereference in DFSck#doWork()
[ https://issues.apache.org/jira/browse/HDFS-7101?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] skrho updated HDFS-7101: Affects Version/s: 2.5.1 Status: Patch Available (was: Open) > Potential null dereference in DFSck#doWork() > > > Key: HDFS-7101 > URL: https://issues.apache.org/jira/browse/HDFS-7101 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.5.1 >Reporter: Ted Yu >Assignee: skrho >Priority: Minor > Attachments: HDFS-7101_001.patch > > > {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)
[jira] [Updated] (HDFS-7101) Potential null dereference in DFSck#doWork()
[ https://issues.apache.org/jira/browse/HDFS-7101?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] skrho updated HDFS-7101: Attachment: HDFS-7101_001.patch > 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 >Assignee: skrho >Priority: Minor > Attachments: HDFS-7101_001.patch > > > {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)