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

Issue 2838023: linux: work around gnome keyring memory corruption (Closed)

Created:
10 years, 6 months ago by Evan Martin
Modified:
9 years, 7 months ago
Reviewers:
Mike Mammarella
CC:
chromium-reviews, ben+cc_chromium.org
Visibility:
Public.

Description

linux: work around gnome keyring memory corruption Older versions of gnome keyring corrupt memory if you fetch too much data from it. Despite our best efforts, we couldn't come up with a way to tell if you're using the broken old version so that we could blacklist it. Instead, we fetch passwords one-by-one, which is slow but tolerable since we do it on a background thread anyway. While I'm here, refactor the code a bit to simplify it. TEST=password manager doesn't crash when using mdm's sample 100 password db with --password-store=gnome on hardy Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=50771

Patch Set 1 #

Patch Set 2 : x #

Total comments: 4

Patch Set 3 : final version for trybots #

Patch Set 4 : now with better defines #

Unified diffs Side-by-side diffs Delta from patch set Stats (+171 lines, -105 lines) Patch
M chrome/browser/password_manager/native_backend_gnome_x.cc View 1 2 3 10 chunks +171 lines, -105 lines 0 comments Download

Messages

Total messages: 1 (0 generated)
Mike Mammarella
10 years, 6 months ago (2010-06-24 05:11:09 UTC) #1
Thanks! LGTM with a few comments.

http://codereview.chromium.org/2838023/diff/2001/3001
File chrome/browser/password_manager/native_backend_gnome_x.cc (right):

http://codereview.chromium.org/2838023/diff/2001/3001#newcode54
chrome/browser/password_manager/native_backend_gnome_x.cc:54:
typeof(&gnome_keyring_##name) wrap_gnome_keyring_##name;
Since you declare our function pointers with types based on the gnome keyring
prototypes, we don't need VerifyGnomeKeyringTypes below any more. Good idea!

http://codereview.chromium.org/2838023/diff/2001/3001#newcode63
chrome/browser/password_manager/native_backend_gnome_x.cc:63:
wrap_gnome_keyring_##name = gnome_keyring_##name;
name = name was to avoid unused variable warnings, but if you remove this anyway
then it doesn't matter.

http://codereview.chromium.org/2838023/diff/2001/3001#newcode139
chrome/browser/password_manager/native_backend_gnome_x.cc:139: // We don't do
the hacky version check here. When linking directly, we assume
This comment can go away.

http://codereview.chromium.org/2838023/diff/2001/3001#newcode453
chrome/browser/password_manager/native_backend_gnome_x.cc:453: // reasonable
unofficial way to do it.  So we workaround by using a
Nit: the verb form of workaround is two words.

Powered by Google App Engine
This is Rietveld 408576698