Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-4546

unclosed instantiation of PrintWriter

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Not A Problem
    • Affects Version/s: 2.3.24
    • Fix Version/s: 2.5.15
    • Component/s: None
    • Labels:
      None

      Description

      In method execute() of class XSLTResult.java (src\core\src\main\java\org\apache\struts2\views\xslt\XSLTResult.java).

      The instantiation of PrintWriter should be closed after all writing is done.

        public void execute(ActionInvocation invocation) throws Exception {
      	…
       	PrintWriter writer = response.getWriter();
      ...
       writer.flush(); // ...and flush...
      }
      

        Attachments

          Activity

            People

            • Assignee:
              sdutry Stefaan Dutry
              Reporter:
              songwang songwanging
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: