HDFS-7101. Potential null dereference in DFSck#doWork(). Contributed by skrho and Ted Yu.
(cherry picked from commit 113af12cfb
)
This commit is contained in:
parent
2d82a21b84
commit
5f4762d950
|
@ -354,7 +354,7 @@ public class DFSck extends Configured implements Tool {
|
||||||
BufferedReader input = new BufferedReader(new InputStreamReader(
|
BufferedReader input = new BufferedReader(new InputStreamReader(
|
||||||
stream, "UTF-8"));
|
stream, "UTF-8"));
|
||||||
String line = null;
|
String line = null;
|
||||||
String lastLine = null;
|
String lastLine = NamenodeFsck.CORRUPT_STATUS;
|
||||||
int errCode = -1;
|
int errCode = -1;
|
||||||
try {
|
try {
|
||||||
while ((line = input.readLine()) != null) {
|
while ((line = input.readLine()) != null) {
|
||||||
|
|
Loading…
Reference in New Issue