code: private void sendResponse(Socket s, short opStatus, long timeout) 
                                                         throws IOException {
      DataOutputStream reply = 
        new DataOutputStream(NetUtils.getOutputStream(s, timeout));
      
      reply.writeShort(opStatus);
      reply.flush();
    }
docs: Utility function for sending a response.
  @param s socket to write to
  @param opStatus status message to write
  @param timeout send timeout