Skip to content

Commit

Permalink
Merge pull request #5535 from Pandrex247/Dont-Set-Buffer-Size-On-Comm…
Browse files Browse the repository at this point in the history
…itted-4.1-Port

Don't attempt to set response buffer size on a committed response
  • Loading branch information
BalusC authored Dec 7, 2024
2 parents 984cc2f + bee1a17 commit d1ca822
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -898,7 +898,11 @@ protected ResponseWriter createResponseWriter(FacesContext context) throws IOExc

// set the buffer for content, -1 indicates nothing should be set.
if (responseBufferSize != -1) {
extContext.setResponseBufferSize(responseBufferSize);
if (!extContext.isResponseCommitted()) {
extContext.setResponseBufferSize(responseBufferSize);
} else {
LOGGER.warning("Skipping attempt to set buffer size on a committed response");
}
}

// get our content type
Expand Down

0 comments on commit d1ca822

Please sign in to comment.