Fixed issue: NETTY-272 HttpMessageEncoder should not prepend/append extra data around HttpChunk content if Transfer-Encoding is not chunked.
* OneToOneEncoder should ignore null because HttpMessageEncoder returns null when HttpChunk.isLast() is true.
This commit is contained in:
parent
661acd24c8
commit
46e9fe364a
@ -66,7 +66,7 @@ public abstract class OneToOneEncoder implements ChannelDownstreamHandler {
|
|||||||
Object encodedMessage = encode(ctx, e.getChannel(), originalMessage);
|
Object encodedMessage = encode(ctx, e.getChannel(), originalMessage);
|
||||||
if (originalMessage == encodedMessage) {
|
if (originalMessage == encodedMessage) {
|
||||||
ctx.sendDownstream(evt);
|
ctx.sendDownstream(evt);
|
||||||
} else {
|
} else if (encodedMessage != null) {
|
||||||
write(ctx, e.getFuture(), encodedMessage, e.getRemoteAddress());
|
write(ctx, e.getFuture(), encodedMessage, e.getRemoteAddress());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user