diff options
author | danakj <danakj@chromium.org> | 2015-03-09 10:45:39 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-03-09 17:46:34 +0000 |
commit | 4ef352de3f24142d38b7d11fe3f9f637b43ee834 (patch) | |
tree | 7f6986711ebbd45505f1c5f8b4e4e2f383f4ff69 /base/observer_list_threadsafe.h | |
parent | d415c687891e096b3e2d10e656842d59a86a51ea (diff) | |
download | chromium_src-4ef352de3f24142d38b7d11fe3f9f637b43ee834.zip chromium_src-4ef352de3f24142d38b7d11fe3f9f637b43ee834.tar.gz chromium_src-4ef352de3f24142d38b7d11fe3f9f637b43ee834.tar.bz2 |
base: Stop passing a non-const ref to ObserverListBase::Iterator.
Pass a pointer instead, as per the style guide. Also makes the
constructor explicit (all callsites already are explicit).
BUG=464816
TBR=blundell@chromium.org,agl,dmichael,garykac
Review URL: https://codereview.chromium.org/982413002
Cr-Commit-Position: refs/heads/master@{#319674}
Diffstat (limited to 'base/observer_list_threadsafe.h')
-rw-r--r-- | base/observer_list_threadsafe.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/base/observer_list_threadsafe.h b/base/observer_list_threadsafe.h index 0830445..46ce880 100644 --- a/base/observer_list_threadsafe.h +++ b/base/observer_list_threadsafe.h @@ -213,7 +213,6 @@ class ObserverListThreadSafe template <class Method, class Params> void NotifyWrapper(ObserverListContext* context, const UnboundMethod<ObserverType, Method, Params>& method) { - // Check that this list still needs notifications. { base::AutoLock lock(list_lock_); @@ -229,7 +228,7 @@ class ObserverListThreadSafe } { - typename ObserverList<ObserverType>::Iterator it(context->list); + typename ObserverList<ObserverType>::Iterator it(&context->list); ObserverType* obs; while ((obs = it.GetNext()) != NULL) method.Run(obs); |