T3rm1 created LOG4J2-1941:
-----------------------------

             Summary: Formatting of stacktrace changed to wrong format for 
exceptions with no message
                 Key: LOG4J2-1941
                 URL: https://issues.apache.org/jira/browse/LOG4J2-1941
             Project: Log4j 2
          Issue Type: Bug
          Components: Core
    Affects Versions: 2.8.2, 2.7
            Reporter: T3rm1


Bug did not occur in 2.5.

The output for the stacktrace of a Throwable has changed after 2.5. The 
behavior was that no exception message was printed when it was null. RIght now 
it will always print the message and in case of null it just prints "null". 
This is even different to the default printStackTrace() formatting which omits 
the message when it is null.

The problem is here: 
https://github.com/apache/logging-log4j2/blob/log4j-2.8.2/log4j-core/src/main/java/org/apache/logging/log4j/core/impl/ThrowableProxy.java#L459

The code always prints a colon and the message. There should be a null check.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to