Add state to sockets to handle multiple reads