diff options
author | mattm@chromium.org <mattm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-08 20:56:49 +0000 |
---|---|---|
committer | mattm@chromium.org <mattm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-08 20:56:49 +0000 |
commit | 378c3fdf56d3f6328632f0e994a678c9387c78d3 (patch) | |
tree | 344afadf27316d241d81129085482c9065ed8097 /chrome/app | |
parent | d1bad238a93b0b3c50bafdc566431d2072f33d44 (diff) | |
download | chromium_src-378c3fdf56d3f6328632f0e994a678c9387c78d3.zip chromium_src-378c3fdf56d3f6328632f0e994a678c9387c78d3.tar.gz chromium_src-378c3fdf56d3f6328632f0e994a678c9387c78d3.tar.bz2 |
Coverity: fix possible leak in VisitSegmentDatabase.
If we get a non-zero segment_id, a zero segment_id, and another non-zero segment_id, the pud for the zero segment_id will be leaked. A non-zero segment_id shouldn't happen since it refers to a primary-key in the segments table, but this changes it to check directly whether a pud has been created, and thus makes it more error-proof. This should be safe, as pud is only stored into the list in two places, in the first it is immediately replaced with a new pud, in the second it is storing the final pud (if any.)
CID=6379
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/265027
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28445 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/app')
0 files changed, 0 insertions, 0 deletions