HDFS-7066. LazyWriter#evictBlocks misses a null check for replicaState. (Contributed by Xiaoyu Yao)

Conflicts:
	hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-6581.txt
This commit is contained in:
arp 2014-09-15 15:28:17 -07:00 committed by Jitendra Pandey
parent b8a2eb793a
commit 6906eccec4
1 changed files with 4 additions and 0 deletions

View File

@ -2410,6 +2410,10 @@ class FsDatasetImpl implements FsDatasetSpi<FsVolumeImpl> {
LazyWriteReplicaTracker.ReplicaState replicaState = LazyWriteReplicaTracker.ReplicaState replicaState =
lazyWriteReplicaTracker.getNextCandidateForEviction(); lazyWriteReplicaTracker.getNextCandidateForEviction();
if (replicaState == null) {
break;
}
if (LOG.isDebugEnabled()) { if (LOG.isDebugEnabled()) {
LOG.debug("Evicting block " + replicaState); LOG.debug("Evicting block " + replicaState);
} }