Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-11264

Potential NPE in DefaultUndertowHttpBinding

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.18.0, 2.18.1, 2.18.2, 2.18.3, 2.19.0
    • 2.18.4, 2.19.1, 2.20.0
    • camel-undertow
    • None
    • Novice

    Description

      There's a potential NPE lurking in DefaultUndertowHttpBinding. We have this logic:

      // we failed due to an exception so print it as plain text
      StringWriter sw = new StringWriter();
      PrintWriter pw = new PrintWriter(sw);
      exception.getCause().printStackTrace(pw);
      

      Unfortuantely, exception.getCause() is not always guaranteed to be present and may be null.

      Attachments

        Issue Links

          Activity

            People

              acosentino Andrea Cosentino
              jamesnetherton James Netherton
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: