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

Unified Diff: net/url_request/url_request_ftp_job.cc

Issue 6488010: Propagate the remote socket address to URLRequest and to ViewHostMsg_FrameNavigate. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 10 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/url_request/url_request_ftp_job.cc
diff --git a/net/url_request/url_request_ftp_job.cc b/net/url_request/url_request_ftp_job.cc
index 8c170ff3580002108259d1972363e18fb2e50c1d..9c77dea3facc3ac6fe0bc61ec030c15c94f5e068 100644
--- a/net/url_request/url_request_ftp_job.cc
+++ b/net/url_request/url_request_ftp_job.cc
@@ -52,6 +52,15 @@ bool URLRequestFtpJob::GetMimeType(std::string* mime_type) const {
return false;
}
+std::string URLRequestFtpJob::GetSocketAddress() const {
+ if (!transaction_.get()) {
Paweł Hajdan Jr. 2011/02/11 19:34:54 It seems that other methods here assume transactio
Brian Ryner 2011/02/11 23:01:07 I was trying to make sure it was safe to call GetS
+ return "";
+ }
+
+ const FtpResponseInfo* response_info = transaction_->GetResponseInfo();
+ return response_info ? response_info->socket_address : "";
Paweł Hajdan Jr. 2011/02/11 19:34:54 Similarly here, do we need to NULL-check?
Brian Ryner 2011/02/11 23:01:07 Here, probably not, it looks like GetResponseInfo(
+}
+
URLRequestFtpJob::~URLRequestFtpJob() {
}

Powered by Google App Engine
This is Rietveld 408576698