diff options
author | lzheng@chromium.org <lzheng@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-14 18:37:53 +0000 |
---|---|---|
committer | lzheng@chromium.org <lzheng@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-14 18:37:53 +0000 |
commit | 8d71797322893a3402cd86723726782bdca31285 (patch) | |
tree | 151cf3a67dc97fee111194505f741ed13a47620d | |
parent | 001f08ab3184a370fdd1e8cf4cef05fa15174bd9 (diff) | |
download | chromium_src-8d71797322893a3402cd86723726782bdca31285.zip chromium_src-8d71797322893a3402cd86723726782bdca31285.tar.gz chromium_src-8d71797322893a3402cd86723726782bdca31285.tar.bz2 |
Remove the unused enlarge.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/6151010
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@71462 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/safe_browsing/safe_browsing_util.cc | 10 | ||||
-rw-r--r-- | chrome/browser/safe_browsing/safe_browsing_util.h | 4 |
2 files changed, 0 insertions, 14 deletions
diff --git a/chrome/browser/safe_browsing/safe_browsing_util.cc b/chrome/browser/safe_browsing/safe_browsing_util.cc index f43ee51..3e449e0 100644 --- a/chrome/browser/safe_browsing/safe_browsing_util.cc +++ b/chrome/browser/safe_browsing/safe_browsing_util.cc @@ -111,16 +111,6 @@ int SBEntry::Size(Type type, int prefix_count) { return sizeof(Data) + prefix_count * PrefixSize(type); } -SBEntry* SBEntry::Enlarge(int extra_prefixes) { - int new_prefix_count = prefix_count() + extra_prefixes; - SBEntry* rv = SBEntry::Create(type(), new_prefix_count); - memcpy(rv, this, Size()); // NOTE: Blows away rv.data_! - // We have to re-set |rv|'s prefix count since we just copied our own over it. - rv->set_prefix_count(new_prefix_count); - Destroy(); - return rv; -} - int SBEntry::ChunkIdAtPrefix(int index) const { if (type() == SUB_PREFIX) return sub_prefixes_[index].add_chunk; diff --git a/chrome/browser/safe_browsing/safe_browsing_util.h b/chrome/browser/safe_browsing/safe_browsing_util.h index b0351c1..85a79ef 100644 --- a/chrome/browser/safe_browsing/safe_browsing_util.h +++ b/chrome/browser/safe_browsing/safe_browsing_util.h @@ -157,10 +157,6 @@ class SBEntry { int chunk_id() const { return data_.chunk_id; } int prefix_count() const { return data_.prefix_count; } - // Returns a new entry that is larger by the given number of prefixes, with - // all the existing data already copied over. The old entry is destroyed. - SBEntry* Enlarge(int extra_prefixes); - // Returns true if this is a prefix as opposed to a full hash. bool IsPrefix() const { return type() == ADD_PREFIX || type() == SUB_PREFIX; |