dht: introduce and enforce a maximum storage size

The default storage limit is 64 MB
This commit is contained in:
Adrien Béraud committed 2016-01-22 02:01:07 -05:00
1 parent b304418d43
commit d5dcfa0889
5 files changed
+187 -78

No files matched your search

+6
View File
@@ -80,6 +80,12 @@ findMapValue(const msgpack::object& map, const std::string& key) {
return nullptr;
}
size_t
Value::size() const
{
return cypher.size() + data.size() + signature.size() + user_type.size();
}
void
Value::msgpack_unpack(msgpack::object o)
{