summaryrefslogtreecommitdiffstats
path: root/chrome/browser/safe_browsing/safe_browsing_store.h
diff options
context:
space:
mode:
authorshess@chromium.org <shess@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-22 20:07:48 +0000
committershess@chromium.org <shess@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-22 20:07:48 +0000
commitb9f11fa51c05d4c9630644925253815da1fb89a2 (patch)
treead5191ee00dd3d5c8bb06d1339a3e055509dd736 /chrome/browser/safe_browsing/safe_browsing_store.h
parent71563f8e5e28e67e877dbbff75449928716b5025 (diff)
downloadchromium_src-b9f11fa51c05d4c9630644925253815da1fb89a2.zip
chromium_src-b9f11fa51c05d4c9630644925253815da1fb89a2.tar.gz
chromium_src-b9f11fa51c05d4c9630644925253815da1fb89a2.tar.bz2
Convert SafeBrowsingStoreFile to do bulk reads and writes.
Read/write the data in the style of fread/fwrite, rather than doing I/O element by element. This lays the groundwork for adding checksumming. BUG=none TEST=none Review URL: http://codereview.chromium.org/650113 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@39619 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/safe_browsing/safe_browsing_store.h')
-rw-r--r--chrome/browser/safe_browsing/safe_browsing_store.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/chrome/browser/safe_browsing/safe_browsing_store.h b/chrome/browser/safe_browsing/safe_browsing_store.h
index 34aa4b2..c1026ef 100644
--- a/chrome/browser/safe_browsing/safe_browsing_store.h
+++ b/chrome/browser/safe_browsing/safe_browsing_store.h
@@ -43,6 +43,7 @@ struct SBAddPrefix {
SBPrefix prefix;
SBAddPrefix(int32 id, SBPrefix p) : chunk_id(id), prefix(p) {}
+ SBAddPrefix() {}
int32 GetAddChunkId() const { return chunk_id; }
SBPrefix GetAddPrefix() const { return prefix; }
@@ -55,6 +56,7 @@ struct SBSubPrefix {
SBSubPrefix(int32 id, int32 add_id, int prefix)
: chunk_id(id), add_chunk_id(add_id), add_prefix(prefix) {}
+ SBSubPrefix() {}
int32 GetAddChunkId() const { return add_chunk_id; }
SBPrefix GetAddPrefix() const { return add_prefix; }
@@ -76,6 +78,8 @@ struct SBAddFullHash {
SBAddFullHash(int32 id, int32 r, SBFullHash h)
: chunk_id(id), received(r), full_hash(h) {}
+ SBAddFullHash() {}
+
int32 GetAddChunkId() const { return chunk_id; }
SBPrefix GetAddPrefix() const { return full_hash.prefix; }
};
@@ -87,6 +91,7 @@ struct SBSubFullHash {
SBSubFullHash(int32 id, int32 add_id, SBFullHash h)
: chunk_id(id), add_chunk_id(add_id), full_hash(h) {}
+ SBSubFullHash() {}
int32 GetAddChunkId() const { return add_chunk_id; }
SBPrefix GetAddPrefix() const { return full_hash.prefix; }