HDFS-17443. add null check for fileSys and cluster before shutting down (#6683)
This commit is contained in:
parent
8528d5783d
commit
f3f6340746
@ -447,8 +447,12 @@ public void testNameEditsConfigsFailure() throws IOException {
|
|||||||
replication, SEED);
|
replication, SEED);
|
||||||
checkFile(fileSys, file1, replication);
|
checkFile(fileSys, file1, replication);
|
||||||
} finally {
|
} finally {
|
||||||
fileSys.close();
|
if (fileSys != null) {
|
||||||
cluster.shutdown();
|
fileSys.close();
|
||||||
|
}
|
||||||
|
if (cluster != null) {
|
||||||
|
cluster.shutdown();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 2
|
// 2
|
||||||
|
Loading…
Reference in New Issue
Block a user