diff --git a/src/java/org/apache/solr/handler/ReplicationHandler.java b/src/java/org/apache/solr/handler/ReplicationHandler.java index b6c4f504fd7..e54cd8b6f40 100644 --- a/src/java/org/apache/solr/handler/ReplicationHandler.java +++ b/src/java/org/apache/solr/handler/ReplicationHandler.java @@ -851,7 +851,7 @@ public class ReplicationHandler extends RequestHandlerBase implements SolrCoreAw } catch (IOException e) { LOG.warn("Unable to get IndexCommit on startup", e); } finally { - s.decref(); + if (s!=null) s.decref(); } } String reserve = (String) master.get(RESERVE);