Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(138)

Unified Diff: net/base/host_resolver_impl_unittest.cc

Issue 3115014: Revert 56384 - Don't resolve IP literals.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/base/host_resolver_impl.cc ('k') | net/base/mock_host_resolver.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/base/host_resolver_impl_unittest.cc
===================================================================
--- net/base/host_resolver_impl_unittest.cc (revision 56384)
+++ net/base/host_resolver_impl_unittest.cc (working copy)
@@ -399,6 +399,11 @@
const int kPortnum = 5555;
HostResolver::RequestInfo info("2001:db8::1", kPortnum);
int err = host_resolver->Resolve(info, &adrlist, NULL, NULL, BoundNetLog());
+ // On computers without IPv6 support, getaddrinfo cannot convert IPv6
+ // address literals to addresses (getaddrinfo returns EAI_NONAME). So this
+ // test has to allow host_resolver->Resolve to fail.
+ if (err == ERR_NAME_NOT_RESOLVED)
+ return;
EXPECT_EQ(OK, err);
const struct addrinfo* ainfo = adrlist.head();
« no previous file with comments | « net/base/host_resolver_impl.cc ('k') | net/base/mock_host_resolver.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698