defend against npe

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1300434 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Mark Robert Miller 2012-03-14 01:34:07 +00:00
parent f7cf65f76c
commit fe9b072490
1 changed files with 3 additions and 1 deletions

View File

@ -308,7 +308,9 @@ public class SolrDispatchFilter implements Filter
for (Entry<String,Slice> entry : entries) {
// first see if we have the leader
ZkNodeProps leaderProps = cloudState.getLeader(collection, entry.getKey());
core = checkProps(cores, path, leaderProps);
if (leaderProps != null) {
core = checkProps(cores, path, leaderProps);
}
if (core != null) {
break done;
}