response.setContentLength(out.size());
try {
out.writeTo(response.getOutputStream());
response.getOutputStream().flush();
} catch (IOException e) {
<BUG>throw createException("Unable write to browser OutputStream", e, request, response);
</BUG>
}
}
<BUG>protected ViewHandlerException createException(String msg, Exception e, HttpServletRequest request, HttpServletResponse response) {
</BUG>
Debug.logError(msg + ": " + e, module);

response.setContentLength(out.size());
try {
out.writeTo(response.getOutputStream());
response.getOutputStream().flush();
} catch (IOException e) {
renderError("Unable to write to OutputStream", e, request, response);
}
}
protected void renderError(String msg, Exception e, HttpServletRequest request, HttpServletResponse response) throws ViewHandlerException {
Debug.logError(msg + ": " + e, module);
