def METHOD_NAME(self):
    LOG.debug("Starting GDB server packet I/O thread")
    self._abstract_socket.set_timeout(self.RECEIVE_TIMEOUT)
    while not self._shutdown_event.is_set():
        try:
            data = self._abstract_socket.read()
            # Handle closed connection
            if len(data) == 0:
                LOG.debug("GDB packet thread: other side closed connection")
                self._closed = True
                break
            TRACE_PACKETS.debug('-->>>> GDB read %d bytes: %s', len(data), data)
            self._buffer += data
        except (ConnectionAbortedError, ConnectionResetError) as err:
            LOG.warning("GDB packet thread: connection unexpectedly closed during receive (%s)", err)
            self._closed = True
            break
        except socket.timeout:
            # Ignore timeouts.
            pass
        except OSError as err:
            LOG.debug("Error in packet IO thread: %s", err)
        if self._shutdown_event.is_set():
            break
        self._process_data()
    LOG.debug("GDB packet thread stopping")