diff --git a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/Server.java b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/Server.java index fb339c02f2..4448164f4b 100644 --- a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/Server.java +++ b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/Server.java @@ -1794,7 +1794,7 @@ public class Connection { private SocketChannel channel; private ByteBuffer data; - private ByteBuffer dataLengthBuffer; + private final ByteBuffer dataLengthBuffer; private LinkedList responseQueue; // number of outstanding rpcs private AtomicInteger rpcCount = new AtomicInteger(); @@ -2838,7 +2838,6 @@ public void setServiceClass(int serviceClass) { private synchronized void close() { disposeSasl(); data = null; - dataLengthBuffer = null; if (!channel.isOpen()) return; try {socket.shutdownOutput();} catch(Exception e) {