You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2020/10/15 09:06:29 UTC
[tomcat] branch master updated: Fix possible NPE. Correct
ExceptionUtils import.
This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/master by this push:
new 4db6733 Fix possible NPE. Correct ExceptionUtils import.
4db6733 is described below
commit 4db67333e133df54cad5a7f51253fc101293ac79
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Thu Oct 15 10:01:57 2020 +0100
Fix possible NPE. Correct ExceptionUtils import.
---
java/org/apache/catalina/valves/JsonErrorReportValve.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/java/org/apache/catalina/valves/JsonErrorReportValve.java b/java/org/apache/catalina/valves/JsonErrorReportValve.java
index a438e77..5233bff 100644
--- a/java/org/apache/catalina/valves/JsonErrorReportValve.java
+++ b/java/org/apache/catalina/valves/JsonErrorReportValve.java
@@ -22,8 +22,8 @@ import java.util.concurrent.atomic.AtomicBoolean;
import org.apache.catalina.connector.Request;
import org.apache.catalina.connector.Response;
-import org.apache.catalina.tribes.util.ExceptionUtils;
import org.apache.coyote.ActionCode;
+import org.apache.tomcat.util.ExceptionUtils;
import org.apache.tomcat.util.res.StringManager;
/**
@@ -75,7 +75,7 @@ public class JsonErrorReportValve extends ErrorReportValve {
String description = null;
description = smClient.getString("http." + statusCode + ".desc");
if (description == null) {
- if (message.isEmpty()) {
+ if (message == null || message.isEmpty()) {
return;
} else {
description = smClient.getString("errorReportValve.noDescription");
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org