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

Unified Diff: net/url_request/ftp_protocol_handler.cc

Issue 10855209: Refactoring: ProtocolHandler::MaybeCreateJob takes NetworkDelegate as argument (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Latest merge Created 8 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/url_request/ftp_protocol_handler.h ('k') | net/url_request/url_request.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/url_request/ftp_protocol_handler.cc
diff --git a/net/url_request/ftp_protocol_handler.cc b/net/url_request/ftp_protocol_handler.cc
index b9dc0fa05f8201cc0ca6b8e21690b7e8934909b5..7d9ba8858547f4945d08d635df7f37e6ddf0a95e 100644
--- a/net/url_request/ftp_protocol_handler.cc
+++ b/net/url_request/ftp_protocol_handler.cc
@@ -15,26 +15,24 @@
namespace net {
FtpProtocolHandler::FtpProtocolHandler(
- NetworkDelegate* network_delegate,
FtpTransactionFactory* ftp_transaction_factory,
FtpAuthCache* ftp_auth_cache)
- : network_delegate_(network_delegate),
- ftp_transaction_factory_(ftp_transaction_factory),
+ : ftp_transaction_factory_(ftp_transaction_factory),
ftp_auth_cache_(ftp_auth_cache) {
DCHECK(ftp_transaction_factory_);
DCHECK(ftp_auth_cache_);
}
URLRequestJob* FtpProtocolHandler::MaybeCreateJob(
- URLRequest* request) const {
+ URLRequest* request, NetworkDelegate* network_delegate) const {
int port = request->url().IntPort();
if (request->url().has_port() &&
!IsPortAllowedByFtp(port) && !IsPortAllowedByOverride(port)) {
- return new URLRequestErrorJob(request, ERR_UNSAFE_PORT);
+ return new URLRequestErrorJob(request, network_delegate, ERR_UNSAFE_PORT);
}
return new URLRequestFtpJob(request,
- network_delegate_,
+ network_delegate,
ftp_transaction_factory_,
ftp_auth_cache_);
}
« no previous file with comments | « net/url_request/ftp_protocol_handler.h ('k') | net/url_request/url_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698