making client::stop synchronous