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

Issue 8592001: Valgrind: Fix a leak in ContentSettingsProvider. (Closed)

Created:
9 years, 1 month ago by James Hawkins
Modified:
9 years, 1 month ago
CC:
chromium-reviews
Visibility:
Public.

Description

Valgrind: Fix a leak in ContentSettingsProvider. If the call to SetWebsiteSetting() fails, the value is still owned by the caller and must be deleted. BUG=none TEST=none R=bauerb@chromium.org Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=110594

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+6 lines, -7 lines) Patch
M chrome/browser/content_settings/content_settings_provider.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/content_settings/host_content_settings_map.cc View 1 chunk +5 lines, -6 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
James Hawkins
9 years, 1 month ago (2011-11-17 21:56:21 UTC) #1
James Hawkins
9 years, 1 month ago (2011-11-17 22:07:14 UTC) #2
Lei Zhang
LGTM for the purposes of fixing the leak. Perhaps the callee should be responsible for ...
9 years, 1 month ago (2011-11-17 22:21:20 UTC) #3
markusheintz
9 years, 1 month ago (2011-11-18 16:26:03 UTC) #4
Thanks a lot for fixing the leak!

I did some investigation to way I didn't catch this leak. It turned out
that when I ran valgrind I set the gtest_filter to tight. Sorry next time
I'll use the valgrind try bot.

However I created CL http://codereview.chromium.org/8528031 to follow up on
this. This CL also catches one more leak.

On Thu, Nov 17, 2011 at 11:21 PM, <thestig@chromium.org> wrote:

> LGTM for the purposes of fixing the leak.
>
> Perhaps the callee should be responsible for taking ownership and freeing
> |value|, even in the case of failure?
>
>
http://codereview.chromium.**org/8592001/<http://codereview.chromium.org/8592...
>



-- 
Markus

Powered by Google App Engine
This is Rietveld 408576698