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

Unified Diff: base/memory/ref_counted_memory.cc

Issue 11830007: Avoid sending notifications when the bitmap data in history has not changed (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Split the changes to MergeFavicon() and SetFavicons() into two CLs as only the changes to MergeFavi… Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/memory/ref_counted_memory.h ('k') | base/memory/ref_counted_memory_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/memory/ref_counted_memory.cc
diff --git a/base/memory/ref_counted_memory.cc b/base/memory/ref_counted_memory.cc
index 9bcde32b60ec77bb1bc88721256f59d0e3f9f67b..b048a6e0d8d2352936e9cb995479058c13f17ba4 100644
--- a/base/memory/ref_counted_memory.cc
+++ b/base/memory/ref_counted_memory.cc
@@ -8,6 +8,13 @@
namespace base {
+bool RefCountedMemory::Equals(
+ const scoped_refptr<RefCountedMemory>& other) const {
+ return other.get() &&
+ size() == other->size() &&
+ (memcmp(front(), other->front(), size()) == 0);
+}
+
RefCountedMemory::RefCountedMemory() {}
RefCountedMemory::~RefCountedMemory() {}
« no previous file with comments | « base/memory/ref_counted_memory.h ('k') | base/memory/ref_counted_memory_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698