From 51a45c9f4dcbdf4816bbd66bdaa4673bd2421f8a Mon Sep 17 00:00:00 2001 From: Mark Robert Miller Date: Wed, 20 Nov 2013 21:59:56 +0000 Subject: [PATCH] SOLR-5479: Deal with null message in SolrLogLayout git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1543966 13f79535-47bb-0310-9956-ffa450edef68 --- solr/core/src/java/org/apache/solr/util/SolrLogLayout.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/solr/core/src/java/org/apache/solr/util/SolrLogLayout.java b/solr/core/src/java/org/apache/solr/util/SolrLogLayout.java index 4fc04e93216..6b6d011acf3 100644 --- a/solr/core/src/java/org/apache/solr/util/SolrLogLayout.java +++ b/solr/core/src/java/org/apache/solr/util/SolrLogLayout.java @@ -112,7 +112,9 @@ public class SolrLogLayout extends Layout { public String _format(LoggingEvent event) { String message = (String) event.getMessage(); - + if (message == null) { + message = ""; + } StringBuilder sb = new StringBuilder(message.length() + 80); long now = event.timeStamp;