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

Unified Diff: chrome/browser/ssl/ssl_blocking_page.cc

Issue 8856010: Remove the wording that suggests it is possible to proceed after fatal SSL error. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years 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 | « chrome/app/google_chrome_strings.grd ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ssl/ssl_blocking_page.cc
===================================================================
--- chrome/browser/ssl/ssl_blocking_page.cc (revision 113437)
+++ chrome/browser/ssl/ssl_blocking_page.cc (working copy)
@@ -6,6 +6,7 @@
#include "base/i18n/rtl.h"
#include "base/metrics/histogram.h"
+#include "base/string16.h"
#include "base/string_piece.h"
#include "base/utf_string_conversions.h"
#include "base/values.h"
@@ -78,7 +79,6 @@
strings.SetString("moreInfoTitle",
l10n_util::GetStringUTF16(IDS_CERT_ERROR_EXTRA_INFO_TITLE));
- SetExtraInfo(&strings, error_info.extra_information());
int resource_id;
if (overridable_) {
@@ -89,12 +89,20 @@
l10n_util::GetStringUTF16(IDS_SSL_BLOCKING_PAGE_PROCEED));
strings.SetString("exit",
l10n_util::GetStringUTF16(IDS_SSL_BLOCKING_PAGE_EXIT));
+
+ // error_info.extra_information() returns const ref, but we need to add
+ // something. So, add to a copy.
+ std::vector<string16> extra_info = error_info.extra_information();
+ extra_info.push_back(
+ l10n_util::GetStringUTF16(IDS_SSL_BLOCKING_PAGE_SHOULD_NOT_PROCEED));
wtc 2011/12/08 00:35:37 Many of the certificate error messages have some s
Ryan Sleevi 2011/12/08 00:45:11 Should this logic be pushed into SSLErrorInfo::Cre
+ SetExtraInfo(&strings, extra_info);
} else {
resource_id = IDR_SSL_ERROR_HTML;
strings.SetString("title",
l10n_util::GetStringUTF16(IDS_SSL_ERROR_PAGE_TITLE));
strings.SetString("back",
l10n_util::GetStringUTF16(IDS_SSL_ERROR_PAGE_BACK));
+ SetExtraInfo(&strings, error_info.extra_information());
}
strings.SetString("textdirection", base::i18n::IsRTL() ? "rtl" : "ltr");
@@ -168,7 +176,7 @@
void SSLBlockingPage::SetExtraInfo(
DictionaryValue* strings,
const std::vector<string16>& extra_info) {
- DCHECK(extra_info.size() < 5); // We allow 5 paragraphs max.
+ DCHECK_LT(extra_info.size(), 5U); // We allow 5 paragraphs max.
const char* keys[5] = {
"moreInfo1", "moreInfo2", "moreInfo3", "moreInfo4", "moreInfo5"
};
« no previous file with comments | « chrome/app/google_chrome_strings.grd ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698