| 250 | |
| 251 | |
| 252 | Status Proxy::SyncRequest(const string& method, |
| 253 | const google::protobuf::Message& req, |
| 254 | google::protobuf::Message* resp, |
| 255 | RpcController* controller) { |
| 256 | Notification note; |
| 257 | AsyncRequest(method, req, DCHECK_NOTNULL(resp), controller, |
| 258 | [¬e]() { note.Notify(); }); |
| 259 | note.WaitForNotification(); |
| 260 | return controller->status(); |
| 261 | } |
| 262 | |
| 263 | void Proxy::set_user_credentials(UserCredentials user_credentials) { |
| 264 | CHECK(base::subtle::NoBarrier_Load(&is_started_) == false) |