threads could pass the nil check. One would acquire the lock and create the sharedClient. The second thread would eventually get the lock and also acquire a sharedClient.