while(receiverThread != null && receiverThread.equals(Thread.currentThread())) {
while(receiverThread != null && receiverThread.equals(Thread.currentThread()) && is_running) {
       public void run() {           byte[] buf=new byte[256]; // start with 256, increase as we go           int len=0;           while(receiverThread != null && receiverThread.equals(Thread.currentThread())) {               try {                   if(in == null) {                       if(log.isErrorEnabled()) log.error("input stream is null !");                       break;                   }                   len=in.readInt();                   if(len > buf.length)                       buf=new byte[len];                   in.readFully(buf, 0, len);                   updateLastAccessed();                   receive(peer_addr, buf, 0, len); // calls receiver.receive(msg)               }               catch(OutOfMemoryError mem_ex) {                   if(log.isWarnEnabled()) log.warn("dropped invalid message, closing connection");                   break; // continue;               }               catch(EOFException eof_ex) {  // peer closed connection                   if(log.isInfoEnabled()) log.info("exception is " + eof_ex);                   notifyConnectionClosed(peer_addr);                   break;               }               catch(IOException io_ex) {                   if(log.isInfoEnabled()) log.info("exception is " + io_ex);                   notifyConnectionClosed(peer_addr);                   break;               }               catch(Throwable e) {                   if(log.isWarnEnabled()) log.warn("exception is " + e);               }           }           if(log.isTraceEnabled())               log.trace("ConnectionTable.Connection.Receiver terminated");           receiverThread=null;           closeSocket();           remove(peer_addr);       }