transport: In processEvents, loop until there is no more data in the receive buffer.