wait for client to connect before continuing