code: def _recv(self, max_size):
          
          # wait for read
          if not self._can_read():
              self.close()
              return None
          # recv
          try:
              r_buffer = self.__sock.recv(max_size)
          except socket.error:
              r_buffer = None
          # handle recv error
          if not r_buffer:
              self.__last_error = const.MB_RECV_ERR
              self.__debug_msg('_recv error')
              self.close()
              return None
          return r_buffer
docs: Receive data over current socket
  
          :param max_size: number of bytes to receive
          :type max_size: int
          :returns: receive data or None if error
          :rtype: str (Python2) or class bytes (Python3) or None