Wait for the socket to fire an event to recover.

This fixes a bug because I would manually start a recovery but the socket
would also fire a socket-error event which would cause another attempt to
recover. Very quickly, each attempt would multiply and it got really
really messy...