summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorbengr@chromium.org <bengr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-02 01:35:17 +0000
committerbengr@chromium.org <bengr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-02 01:35:17 +0000
commit421cdcd6598d9ed9c21f6ac00a967be79626a5e1 (patch)
tree6a653bceb779203cd6f5cf135a0f6ca61e17dfb3 /net
parentd00029c7d787deb049ebc642674bac30e713c245 (diff)
downloadchromium_src-421cdcd6598d9ed9c21f6ac00a967be79626a5e1.zip
chromium_src-421cdcd6598d9ed9c21f6ac00a967be79626a5e1.tar.gz
chromium_src-421cdcd6598d9ed9c21f6ac00a967be79626a5e1.tar.bz2
Updated devtools listing of headers on Android
No more try. Just do. BUG=179382 NOTRY=true Review URL: https://chromiumcodereview.appspot.com/12379051 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@185649 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net')
-rw-r--r--net/spdy/spdy_header_block.cc10
-rw-r--r--net/spdy/spdy_session.cc11
2 files changed, 21 insertions, 0 deletions
diff --git a/net/spdy/spdy_header_block.cc b/net/spdy/spdy_header_block.cc
index 0b24a2a..acdbdde 100644
--- a/net/spdy/spdy_header_block.cc
+++ b/net/spdy/spdy_header_block.cc
@@ -15,8 +15,18 @@ Value* SpdyHeaderBlockNetLogCallback(
DictionaryValue* headers_dict = new DictionaryValue();
for (SpdyHeaderBlock::const_iterator it = headers->begin();
it != headers->end(); ++it) {
+#if defined(OS_ANDROID)
+ if (it->first == "proxy-authorization") {
+ headers_dict->SetWithoutPathExpansion(
+ it->first, new StringValue("[elided]"));
+ } else {
+ headers_dict->SetWithoutPathExpansion(
+ it->first, new StringValue(it->second));
+ }
+#else
headers_dict->SetWithoutPathExpansion(
it->first, new StringValue(it->second));
+#endif
}
dict->Set("headers", headers_dict);
return dict;
diff --git a/net/spdy/spdy_session.cc b/net/spdy/spdy_session.cc
index a2b5da4..6f7d9ca 100644
--- a/net/spdy/spdy_session.cc
+++ b/net/spdy/spdy_session.cc
@@ -62,8 +62,19 @@ base::Value* NetLogSpdySynCallback(const SpdyHeaderBlock* headers,
base::ListValue* headers_list = new base::ListValue();
for (SpdyHeaderBlock::const_iterator it = headers->begin();
it != headers->end(); ++it) {
+#if defined(OS_ANDROID)
+ if (it->first == "proxy-authorization") {
+ headers_list->Append(new base::StringValue(base::StringPrintf(
+ "%s: %s", it->first.c_str(), "[elided]")));
+ } else {
+ headers_list->Append(new base::StringValue(base::StringPrintf(
+ "%s: %s", it->first.c_str(), it->second.c_str())));
+ }
+#else
headers_list->Append(new base::StringValue(base::StringPrintf(
"%s: %s", it->first.c_str(), it->second.c_str())));
+#endif
+
}
dict->SetBoolean("fin", fin);
dict->SetBoolean("unidirectional", unidirectional);