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

Unified Diff: net/socket/ssl_test_util.cc

Issue 201083: Cache login identity for NewFTP transactions. (Closed)
Patch Set: better Created 11 years, 3 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/socket/ssl_test_util.cc
diff --git a/net/socket/ssl_test_util.cc b/net/socket/ssl_test_util.cc
index 7e73f1e800189188b3b33d40b1fc3c8161397139..da17ecdd958b11c08f5c68af71df9b0ccc53ba31 100644
--- a/net/socket/ssl_test_util.cc
+++ b/net/socket/ssl_test_util.cc
@@ -138,6 +138,7 @@ const wchar_t TestServerLauncher::kCertIssuerName[] = L"Test CA";
TestServerLauncher::TestServerLauncher() : process_handle_(NULL),
forking_(false),
+ ftp_enable_anonymous_(false),
connection_attempts_(10),
connection_timeout_(1000)
#if defined(OS_LINUX)
@@ -254,8 +255,11 @@ bool TestServerLauncher::Start(Protocol protocol,
L"\"" + testserver_path.ToWStringHack() +
L"\" --port=" + UTF8ToWide(port_str) +
L" --data-dir=\"" + document_root_dir_.ToWStringHack() + L"\"";
- if (protocol == ProtoFTP)
- command_line.append(L" -f");
+ if (protocol == ProtoFTP) {
+ command_line.append(L" --ftp");
+ if (ftp_enable_anonymous_)
+ command_line.append(L" --ftp-enable-anonymous");
+ }
if (!cert_path.value().empty()) {
command_line.append(L" --https=\"");
command_line.append(cert_path.ToWStringHack());
@@ -280,8 +284,11 @@ bool TestServerLauncher::Start(Protocol protocol,
command_line.push_back("--port=" + port_str);
command_line.push_back("--data-dir=" +
WideToUTF8(document_root_dir_.ToWStringHack()));
- if (protocol == ProtoFTP)
- command_line.push_back("-f");
+ if (protocol == ProtoFTP) {
+ command_line.push_back("--ftp");
+ if (ftp_enable_anonymous_)
+ command_line.push_back("--ftp-enable-anonymous");
+ }
if (!cert_path.value().empty())
command_line.push_back("--https=" + WideToUTF8(cert_path.ToWStringHack()));
if (forking_)

Powered by Google App Engine
This is Rietveld 408576698