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

Issue 665283002: Fix crash in ChromeZoomLevelPrefs::ExtractPerHostZoomLevels(). (Closed)

Created:
6 years, 2 months ago by wjmaclean
Modified:
6 years, 2 months ago
Reviewers:
Bernhard Bauer
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@wjmResetZoomLevel
Project:
chromium
Visibility:
Public.

Description

Fix crash in ChromeZoomLevelPrefs::ExtractPerHostZoomLevels(). This CL fixes a crash that occurs when ExtractPerHostZoomLevels is called with a legacy per-host zoom level dictionary. In this case the sanitization code will fail to find a partition key and subsequently dereference a null pointer. Since the legacy dictionary will be deleted immediately after the function exits, we just skip the sanitization in this case. BUG=424540 Committed: https://crrev.com/d94fd1d623893516b98e59e2b79e512ac26556f4 Cr-Commit-Position: refs/heads/master@{#300501}

Patch Set 1 #

Total comments: 3

Patch Set 2 : Convert parameter to bool. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+20 lines, -4 lines) Patch
M chrome/browser/prefs/browser_prefs.cc View 1 1 chunk +4 lines, -1 line 0 comments Download
M chrome/browser/ui/zoom/chrome_zoom_level_prefs.h View 1 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/ui/zoom/chrome_zoom_level_prefs.cc View 1 3 chunks +14 lines, -2 lines 0 comments Download

Messages

Total messages: 13 (4 generated)
wjmaclean
bauerb@ - can you please take a look at this short CL?
6 years, 2 months ago (2014-10-21 13:36:31 UTC) #2
Bernhard Bauer
LGTM with a suggestion: https://codereview.chromium.org/665283002/diff/1/chrome/browser/ui/zoom/chrome_zoom_level_prefs.h File chrome/browser/ui/zoom/chrome_zoom_level_prefs.h (right): https://codereview.chromium.org/665283002/diff/1/chrome/browser/ui/zoom/chrome_zoom_level_prefs.h#newcode57 chrome/browser/ui/zoom/chrome_zoom_level_prefs.h:57: const char* dictionary_path); An alternative ...
6 years, 2 months ago (2014-10-21 14:13:13 UTC) #3
wjmaclean
https://codereview.chromium.org/665283002/diff/1/chrome/browser/ui/zoom/chrome_zoom_level_prefs.h File chrome/browser/ui/zoom/chrome_zoom_level_prefs.h (right): https://codereview.chromium.org/665283002/diff/1/chrome/browser/ui/zoom/chrome_zoom_level_prefs.h#newcode57 chrome/browser/ui/zoom/chrome_zoom_level_prefs.h:57: const char* dictionary_path); On 2014/10/21 14:13:13, Bernhard Bauer wrote: ...
6 years, 2 months ago (2014-10-21 14:21:49 UTC) #4
Bernhard Bauer
https://codereview.chromium.org/665283002/diff/1/chrome/browser/ui/zoom/chrome_zoom_level_prefs.h File chrome/browser/ui/zoom/chrome_zoom_level_prefs.h (right): https://codereview.chromium.org/665283002/diff/1/chrome/browser/ui/zoom/chrome_zoom_level_prefs.h#newcode57 chrome/browser/ui/zoom/chrome_zoom_level_prefs.h:57: const char* dictionary_path); On 2014/10/21 14:21:49, wjmaclean wrote: > ...
6 years, 2 months ago (2014-10-21 14:26:15 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/665283002/20001
6 years, 2 months ago (2014-10-21 15:12:59 UTC) #7
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_rel_swarming on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_swarming/builds/27641)
6 years, 2 months ago (2014-10-21 16:16:51 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/665283002/20001
6 years, 2 months ago (2014-10-21 16:19:49 UTC) #11
commit-bot: I haz the power
Committed patchset #2 (id:20001)
6 years, 2 months ago (2014-10-21 16:47:34 UTC) #12
commit-bot: I haz the power
6 years, 2 months ago (2014-10-21 16:48:39 UTC) #13
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/d94fd1d623893516b98e59e2b79e512ac26556f4
Cr-Commit-Position: refs/heads/master@{#300501}

Powered by Google App Engine
This is Rietveld 408576698