Skip to content

Commit

Permalink
Expect:100-continue fixes for Netty
Browse files Browse the repository at this point in the history
Signed-off-by: Maxim Nesen <[email protected]>
  • Loading branch information
senivam committed Oct 5, 2023
1 parent c0598c9 commit ccf434d
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,10 @@ public void invoke(ClientRequest request, HttpRequest extensionParam) {
final boolean allowStreaming = length > expectContinueSizeThreshold
|| entityProcessing == RequestEntityProcessing.CHUNKED;

if (extensionParam.protocolVersion().equals(HttpVersion.HTTP_1_1)
&& (!Boolean.TRUE.equals(expectContinueActivated)
if (!extensionParam.protocolVersion().equals(HttpVersion.HTTP_1_1)
|| !Boolean.TRUE.equals(expectContinueActivated)
|| !request.hasEntity()
|| !allowStreaming)) {
|| !allowStreaming) {
return;
}
extensionParam.headers().add(HttpHeaderNames.EXPECT, HttpHeaderValues.CONTINUE);
Expand Down

0 comments on commit ccf434d

Please sign in to comment.