aboutsummaryrefslogtreecommitdiff
path: root/src/database-leveldb.h
diff options
context:
space:
mode:
authorLoic Blot <loic.blot@unix-experience.fr>2016-05-14 12:23:15 +0200
committerLoic Blot <loic.blot@unix-experience.fr>2016-05-17 06:52:16 +0200
commit143401451c457da5079b2970fe260acea45bd85a (patch)
tree390c729ba28f974bf422d441dfd8dd7e817e4127 /src/database-leveldb.h
parentdecbd396df0855f0a356c836cf7c0c5b133964cf (diff)
downloadminetest-143401451c457da5079b2970fe260acea45bd85a.tar.gz
minetest-143401451c457da5079b2970fe260acea45bd85a.tar.bz2
minetest-143401451c457da5079b2970fe260acea45bd85a.zip
DB::loadBlock copy removal & DB backend cleanup
* Remove the copy from db::loadBlock by using a pointer to the destination * cleanup db backend, the child backend doesn't have to set their functions as virtual
Diffstat (limited to 'src/database-leveldb.h')
-rw-r--r--src/database-leveldb.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/database-leveldb.h b/src/database-leveldb.h
index 4afe2fdc7..3993db0c3 100644
--- a/src/database-leveldb.h
+++ b/src/database-leveldb.h
@@ -34,10 +34,10 @@ public:
Database_LevelDB(const std::string &savedir);
~Database_LevelDB();
- virtual bool saveBlock(const v3s16 &pos, const std::string &data);
- virtual std::string loadBlock(const v3s16 &pos);
- virtual bool deleteBlock(const v3s16 &pos);
- virtual void listAllLoadableBlocks(std::vector<v3s16> &dst);
+ bool saveBlock(const v3s16 &pos, const std::string &data);
+ void loadBlock(const v3s16 &pos, std::string *block);
+ bool deleteBlock(const v3s16 &pos);
+ void listAllLoadableBlocks(std::vector<v3s16> &dst);
private:
leveldb::DB *m_database;