1
0
Fork 0

Bug fix/fixes 2808 (#3156)

* fixed jslint warnings

* fix undefined behavior

* move check into if, so check tools do not complain
This commit is contained in:
Jan 2017-08-28 15:16:41 +02:00 committed by GitHub
parent 18e8c19271
commit c29a2745d2
3 changed files with 5 additions and 2 deletions

View File

@ -1428,11 +1428,13 @@ Result RocksDBEngine::dropDatabase(TRI_voc_tick_t id) {
// because it will simply remain there and be ignored on subsequent starts
TRI_UnlinkFile(versionFilename(id).c_str());
#ifdef ARANGODB_ENABLE_MAINTAINER_MODE
if (numDocsLeft > 0) {
std::string errorMsg("deletion check in drop database failed - not all documents have been deleted. remaining: ");
errorMsg.append(std::to_string(numDocsLeft));
THROW_ARANGO_EXCEPTION_MESSAGE(TRI_ERROR_INTERNAL, errorMsg);
}
#endif
return res;
}

View File

@ -120,6 +120,7 @@ class RocksDBValue {
RocksDBValue& operator=(RocksDBValue&& other) noexcept {
TRI_ASSERT(_type == other._type);
_buffer = std::move(other._buffer);
return *this;
}
private:

View File

@ -89,7 +89,7 @@ describe('_api/gharial', () => {
do {
wait(0.1);
req = request.get(url + "/" + graphName);
} while (req.statusCode != 200);
} while (req.statusCode !== 200);
expect(db._collection(eColName)).to.not.be.null;
expect(db._collection(vColName)).to.not.be.null;
@ -123,7 +123,7 @@ describe('_api/gharial', () => {
do {
wait(0.1);
req = request.get(url + "/" + graphName);
} while (req.statusCode != 200);
} while (req.statusCode !== 200);
expect(db._collection(eColName)).to.not.be.null;
expect(db._collection(vColName)).to.not.be.null;