From 33fca12d265b8129e6cff8fc1fc9ad7b34a19bab Mon Sep 17 00:00:00 2001 From: "vadimt@chromium.org" Date: Wed, 11 Dec 2013 01:48:50 +0000 Subject: Revert 239921 "Revert 239759 "The comment in base64.h implies th..." ***************** Reverting the revert. Congrats, the original CL wasn't the cause for the failure; sorry for the mess. ***************** > Revert 239759 "The comment in base64.h implies that base::Base64..." > > > The comment in base64.h implies that base::Base64Encode() can return false, but > > this cannot happen in practice. Fix the comment. > > > > The implementation of Base64Encode() attempts to check for the return value > > MODP_B64_ERROR as a failure, but modp_b64_encode() cannot return this > > value. Remove the check. > > > > Remove unneeded integer cast. > > > > Change the return type to void. > > > > BUG=323357 > > TEST=base_unittests, compile all > > TBR=jochen@chromium.org,miket@chromium.org,joi@chromium.org,akalin@chromium.org,sergeyu@chromium.org > > > > Review URL: https://codereview.chromium.org/86913002 > > TBR=ricea@chromium.org > > Review URL: https://codereview.chromium.org/101113004 TBR=vadimt@chromium.org Review URL: https://codereview.chromium.org/111883004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@239944 0039d316-1c4b-4281-b951-d872f2087c98 --- net/test/spawned_test_server/base_test_server.cc | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'net/test/spawned_test_server') diff --git a/net/test/spawned_test_server/base_test_server.cc b/net/test/spawned_test_server/base_test_server.cc index 775341b..7ef2aba 100644 --- a/net/test/spawned_test_server/base_test_server.cc +++ b/net/test/spawned_test_server/base_test_server.cc @@ -226,10 +226,8 @@ bool BaseTestServer::GetFilePathWithReplacements( const std::string& new_text = it->second; std::string base64_old; std::string base64_new; - if (!base::Base64Encode(old_text, &base64_old)) - return false; - if (!base::Base64Encode(new_text, &base64_new)) - return false; + base::Base64Encode(old_text, &base64_old); + base::Base64Encode(new_text, &base64_new); if (first_query_parameter) { new_file_path += "?"; first_query_parameter = false; @@ -400,8 +398,7 @@ bool BaseTestServer::GenerateArguments(base::DictionaryValue* arguments) const { } if (!ssl_options_.signed_cert_timestamps.empty()) { std::string b64_scts; - if (!base::Base64Encode(ssl_options_.signed_cert_timestamps, &b64_scts)) - return false; + base::Base64Encode(ssl_options_.signed_cert_timestamps, &b64_scts); arguments->SetString("signed-cert-timestamps", b64_scts); } } -- cgit v1.1