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

Issue 7024037: Fix bug in ObserverListThreadsafe::RemoveObserver (Closed)

Created:
9 years, 6 months ago by akalin
Modified:
9 years, 6 months ago
CC:
chromium-reviews, Paweł Hajdan Jr., brettw-cc_chromium.org
Visibility:
Public.

Description

Fix bug in ObserverListThreadsafe::RemoveObserver Like ObserverList, ObserverListThreadSafe::RemoveObserver should do nothing if the observer isn't in the list. Instead, it causes weird bugs if the list has 0 or 1 existing elements. Add comments clarifying semantics of AddObserver/RemoveObserver. Change AddObserver to do nothing in release mode if it tries to add an existing observer. BUG=84922 TEST= Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=87944

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+54 lines, -14 lines) Patch
M base/observer_list.h View 1 chunk +8 lines, -4 lines 0 comments Download
M base/observer_list_threadsafe.h View 3 chunks +12 lines, -9 lines 0 comments Download
M base/observer_list_unittest.cc View 3 chunks +34 lines, -1 line 0 comments Download

Messages

Total messages: 6 (0 generated)
akalin
+willchan for review
9 years, 6 months ago (2011-06-04 03:37:13 UTC) #1
willchan no longer on Chromium
You've definitely made the implementations consistent, and this is good, but I'm not sure that ...
9 years, 6 months ago (2011-06-04 18:01:19 UTC) #2
akalin
On 2011/06/04 18:01:19, willchan wrote: > You've definitely made the implementations consistent, and this is ...
9 years, 6 months ago (2011-06-04 18:56:33 UTC) #3
willchan no longer on Chromium
On Sat, Jun 4, 2011 at 8:56 PM, <akalin@chromium.org> wrote: > On 2011/06/04 18:01:19, willchan ...
9 years, 6 months ago (2011-06-04 19:14:02 UTC) #4
akalin
> This argument makes sense, and I suspect it's the more popular > convention in ...
9 years, 6 months ago (2011-06-05 06:17:30 UTC) #5
commit-bot: I haz the power
9 years, 6 months ago (2011-06-05 07:07:14 UTC) #6
Change committed as 87944

Powered by Google App Engine
This is Rietveld 408576698