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

Unified Diff: net/spdy/spdy_http_stream.cc

Issue 6369003: New extension API: "tab.socketAddress" (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 9 years, 11 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
Index: net/spdy/spdy_http_stream.cc
===================================================================
--- net/spdy/spdy_http_stream.cc (revision 71766)
+++ net/spdy/spdy_http_stream.cc (working copy)
@@ -230,6 +230,12 @@
response_info_ = response;
+ // Put the peer's ip:port into the response, for inquisitive users.
+ AddressList address;
+ stream_->GetPeerAddress(&address);
+ response_info_->socket_address =
+ address.head() ? NetAddressToStringWithPort(address.head()) : "";
+
bool has_upload_data = request_body_stream_.get() != NULL;
int result = stream_->SendRequest(has_upload_data);
if (result == ERR_IO_PENDING) {

Powered by Google App Engine
This is Rietveld 408576698