Reconnect to discoverd when the connection drops

This needs to be protected by a mutex, ditto for the read above.