Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion netty/src/main/java/io/grpc/netty/NettyServerHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -761,7 +761,8 @@ private final class KeepAlivePinger implements KeepAliveManager.KeepAlivePinger
@Override
public void ping() {
ChannelFuture pingFuture = encoder().writePing(
ctx, false /* isAck */, KEEPALIVE_PING_BUF, ctx.newPromise());
// slice KEEPALIVE_PING_BUF because tls handler may modify the reader index
ctx, false /* isAck */, KEEPALIVE_PING_BUF.slice(), ctx.newPromise());
ctx.flush();
if (transportTracer != null) {
pingFuture.addListener(new ChannelFutureListener() {
Expand Down