Skip to content

Commit d9de9f2

Browse files
committedDec 3, 2013
Fix LevelDB maps
1 parent 2330267 commit d9de9f2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

‎src/database-leveldb.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ MapBlock* Database_LevelDB::loadBlock(v3s16 blockpos)
9494
std::string datastr;
9595
leveldb::Status s = m_database->Get(leveldb::ReadOptions(),
9696
i64tos(getBlockAsInteger(blockpos)), &datastr);
97-
if (datastr.length() == 0) {
97+
if (datastr.length() == 0 && s.ok()) {
9898
errorstream << "Blank block data in database (datastr.length() == 0) ("
9999
<< blockpos.X << "," << blockpos.Y << "," << blockpos.Z << ")" << std::endl;
100100

0 commit comments

Comments
 (0)
Please sign in to comment.