WW-4515 Convert try blocks to try-with-resources

This commit is contained in:
Aaron Johnson
2015-06-17 09:49:26 -05:00
parent c71c3def74
commit 0b19499ffd
@@ -396,6 +396,7 @@ public class JasperReportsResult extends StrutsResultSupport implements JasperRe
*/
private void writeReport(HttpServletResponse response, ByteArrayOutputStream output) throws ServletException {
try (OutputStream outputStream = response.getOutputStream()) {
output.writeTo(output);
outputStream.flush();
} catch (IOException e) {
LOG.error("Error writing report output", e);