diff options
Diffstat (limited to 'base/memory/weak_ptr.h')
-rw-r--r-- | base/memory/weak_ptr.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/base/memory/weak_ptr.h b/base/memory/weak_ptr.h index c0ba7f5..b66f024 100644 --- a/base/memory/weak_ptr.h +++ b/base/memory/weak_ptr.h @@ -171,9 +171,9 @@ class WeakPtr : public internal::WeakPtrBase { T* get() const { return ref_.is_valid() ? ptr_ : NULL; } operator T*() const { return get(); } - T* operator*() const { + T& operator*() const { DCHECK(get() != NULL); - return get(); + return *get(); } T* operator->() const { DCHECK(get() != NULL); |