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

Unified Diff: app/resource_bundle_win.cc

Issue 196132: Print a stacktrace when we can't find a string resource (on Windows). (Closed)
Patch Set: 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: app/resource_bundle_win.cc
diff --git a/app/resource_bundle_win.cc b/app/resource_bundle_win.cc
index 35264816f9afa2a9770b180019fe80dc3402c6a7..fc9e36027f78dcb24d5e209b5fc13f870c2cd3c5 100644
--- a/app/resource_bundle_win.cc
+++ b/app/resource_bundle_win.cc
@@ -9,6 +9,7 @@
#include "app/app_paths.h"
#include "app/gfx/font.h"
#include "app/l10n_util.h"
+#include "base/debug_util.h"
#include "base/file_util.h"
#include "base/logging.h"
#include "base/path_service.h"
@@ -133,6 +134,7 @@ string16 ResourceBundle::GetLocalizedString(int message_id) {
// If for some reason we were unable to load a resource dll, return an empty
// string (better than crashing).
if (!locale_resources_data_) {
+ StackTrace().PrintBacktrace(); // See http://crbug.com/21925.
LOG(WARNING) << "locale resources are not loaded";
return string16();
}
@@ -149,6 +151,7 @@ string16 ResourceBundle::GetLocalizedString(int message_id) {
image = AtlGetStringResourceImage(_AtlBaseModule.GetModuleInstance(),
message_id);
if (!image) {
+ StackTrace().PrintBacktrace(); // See http://crbug.com/21925.
NOTREACHED() << "unable to find resource: " << message_id;
return std::wstring();
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698