summaryrefslogtreecommitdiffstats
path: root/net/base/net_util.cc
diff options
context:
space:
mode:
authortfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-25 02:25:06 +0000
committertfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-25 02:25:06 +0000
commitd8eb842474ce559113a9b0ead0610973985bf693 (patch)
tree817d637b7bfffa8bebe3d1de0af0aea05d72a8a7 /net/base/net_util.cc
parent928930d76cb018b8a496dbdf7166178ef8fab1bf (diff)
downloadchromium_src-d8eb842474ce559113a9b0ead0610973985bf693.zip
chromium_src-d8eb842474ce559113a9b0ead0610973985bf693.tar.gz
chromium_src-d8eb842474ce559113a9b0ead0610973985bf693.tar.bz2
net: Append base:: in the StringPrintf calls.
(Note: This is a TODO in string_util.h) BUG=None TEST=trybots Review URL: http://codereview.chromium.org/3390026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@60555 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/base/net_util.cc')
-rw-r--r--net/base/net_util.cc12
1 files changed, 7 insertions, 5 deletions
diff --git a/net/base/net_util.cc b/net/base/net_util.cc
index 0935635..ddc1da7 100644
--- a/net/base/net_util.cc
+++ b/net/base/net_util.cc
@@ -50,15 +50,16 @@
#include "base/string_split.h"
#include "base/string_tokenizer.h"
#include "base/string_util.h"
+#include "base/stringprintf.h"
#include "base/sys_string_conversions.h"
#include "base/time.h"
#include "base/utf_offset_string_conversions.h"
#include "base/utf_string_conversions.h"
-#include "grit/net_resources.h"
#include "googleurl/src/gurl.h"
#include "googleurl/src/url_canon.h"
#include "googleurl/src/url_canon_ip.h"
#include "googleurl/src/url_parse.h"
+#include "grit/net_resources.h"
#include "net/base/dns_util.h"
#include "net/base/escape.h"
#include "net/base/net_module.h"
@@ -1509,14 +1510,15 @@ bool ParseHostAndPort(const std::string& host_and_port,
std::string GetHostAndPort(const GURL& url) {
// For IPv6 literals, GURL::host() already includes the brackets so it is
// safe to just append a colon.
- return StringPrintf("%s:%d", url.host().c_str(), url.EffectiveIntPort());
+ return base::StringPrintf("%s:%d", url.host().c_str(),
+ url.EffectiveIntPort());
}
std::string GetHostAndOptionalPort(const GURL& url) {
// For IPv6 literals, GURL::host() already includes the brackets
// so it is safe to just append a colon.
if (url.has_port())
- return StringPrintf("%s:%s", url.host().c_str(), url.port().c_str());
+ return base::StringPrintf("%s:%s", url.host().c_str(), url.port().c_str());
return url.host();
}
@@ -1547,10 +1549,10 @@ std::string NetAddressToStringWithPort(const struct addrinfo* net_address) {
if (ip_address_string.find(':') != std::string::npos) {
// Surround with square brackets to avoid ambiguity.
- return StringPrintf("[%s]:%d", ip_address_string.c_str(), port);
+ return base::StringPrintf("[%s]:%d", ip_address_string.c_str(), port);
}
- return StringPrintf("%s:%d", ip_address_string.c_str(), port);
+ return base::StringPrintf("%s:%d", ip_address_string.c_str(), port);
}
std::string GetHostName() {