https://issues.apache.org/bugzilla/show_bug.cgi?id=53071

             Bug #: 53071
           Summary: ErrorReportValve ignores message from throwable
           Product: Tomcat 6
           Version: 6.0.35
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Catalina
        AssignedTo: dev@tomcat.apache.org
        ReportedBy: 1983-01...@gmx.net
    Classification: Unclassified


When setting

> request.setAttribute(Globals.EXCEPTION_ATTR, e);
> response.sendError(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);

in a server-side component the throwable#getMessage is completely ignored and
only the stacktrace is shown. Message is not retrieved. Line 161 has to be
simply replaced with

> if (throwable != null)
>   message = RequestUtil.filter(throwable.getMessage());
> else
>   message = RequestUtil.filter(response.getMessage());

The throwable message is nicely displayed.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to