diff options
Diffstat (limited to 'net/base/mock_host_resolver.cc')
-rw-r--r-- | net/base/mock_host_resolver.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/net/base/mock_host_resolver.cc b/net/base/mock_host_resolver.cc index a41a0ce..36603f1 100644 --- a/net/base/mock_host_resolver.cc +++ b/net/base/mock_host_resolver.cc @@ -319,8 +319,10 @@ int RuleBasedHostResolverProc::Resolve(const std::string& host, host_resolver_flags; if (matches_flags && matches_address_family && MatchPattern(host, r->host_pattern)) { - if (r->latency_ms != 0) - base::PlatformThread::Sleep(r->latency_ms); + if (r->latency_ms != 0) { + base::PlatformThread::Sleep( + base::TimeDelta::FromMilliseconds(r->latency_ms)); + } // Remap to a new host. const std::string& effective_host = |