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

Unified Diff: chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_browser.cc

Issue 12212038: Do not pass NULL to GetAsString(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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: chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_browser.cc
diff --git a/chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_browser.cc b/chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_browser.cc
index 01a4a713fbe7f2a70ae3d940f01457fa43907016..7f42aeb8d2ca343c1ae9468687b8b036ef1b694d 100644
--- a/chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_browser.cc
+++ b/chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_browser.cc
@@ -197,8 +197,9 @@ std::string GetPrefForRootWindow(PrefService* pref_service,
for (base::DictionaryValue::Iterator iter(*shelf_prefs);
!iter.IsAtEnd(); iter.Advance()) {
const base::DictionaryValue* display_pref = NULL;
+ std::string unused_value;
if (iter.value().GetAsDictionary(&display_pref) &&
- display_pref->GetString(path, static_cast<std::string*>(NULL))) {
+ display_pref->GetString(path, &unused_value)) {
has_per_display_prefs = true;
break;
}

Powered by Google App Engine
This is Rietveld 408576698