Remove synchronized in SPDY code

This commit is contained in:
Norman Maurer 2013-07-29 08:33:20 +02:00
parent 00f1533fa9
commit 4222610b2a
3 changed files with 4 additions and 6 deletions

View File

@ -65,9 +65,7 @@ public class SpdyFrameEncoder extends MessageToByteEncoder<SpdyFrame> {
ctx.channel().closeFuture().addListener(new ChannelFutureListener() {
@Override
public void operationComplete(ChannelFuture future) throws Exception {
synchronized (headerBlockEncoder) {
headerBlockEncoder.end();
}
headerBlockEncoder.end();
}
});
}

View File

@ -98,7 +98,7 @@ class SpdyHeaderBlockJZlibEncoder extends SpdyHeaderBlockRawEncoder {
}
@Override
public synchronized ByteBuf encode(ChannelHandlerContext ctx, SpdyHeadersFrame frame) throws Exception {
public ByteBuf encode(ChannelHandlerContext ctx, SpdyHeadersFrame frame) throws Exception {
if (frame == null) {
throw new IllegalArgumentException("frame");
}
@ -119,7 +119,7 @@ class SpdyHeaderBlockJZlibEncoder extends SpdyHeaderBlockRawEncoder {
}
@Override
public synchronized void end() {
public void end() {
if (finished) {
return;
}

View File

@ -59,7 +59,7 @@ class SpdyHeaderBlockZlibEncoder extends SpdyHeaderBlockRawEncoder {
}
@Override
public synchronized ByteBuf encode(ChannelHandlerContext ctx, SpdyHeadersFrame frame) throws Exception {
public ByteBuf encode(ChannelHandlerContext ctx, SpdyHeadersFrame frame) throws Exception {
if (frame == null) {
throw new IllegalArgumentException("frame");
}