mirror of https://gitee.com/bigwinds/arangodb
fix issues found by coverity scan tool
This commit is contained in:
parent
1952b75b75
commit
2d96b9ab4c
|
@ -267,7 +267,6 @@ bool RocksDBEdgeIndexIterator::nextExtra(ExtraCallback const& cb,
|
||||||
_builderIterator = VPackArrayIterator(
|
_builderIterator = VPackArrayIterator(
|
||||||
arangodb::basics::VelocyPackHelper::EmptyArrayValue());
|
arangodb::basics::VelocyPackHelper::EmptyArrayValue());
|
||||||
} else {
|
} else {
|
||||||
_copyCounter++;
|
|
||||||
// We need to copy it.
|
// We need to copy it.
|
||||||
// And then we just get back to beginning of the loop
|
// And then we just get back to beginning of the loop
|
||||||
_builder.clear();
|
_builder.clear();
|
||||||
|
|
|
@ -77,8 +77,6 @@ class RocksDBEdgeIndexIterator final : public IndexIterator {
|
||||||
std::shared_ptr<cache::Cache> _cache;
|
std::shared_ptr<cache::Cache> _cache;
|
||||||
arangodb::velocypack::ArrayIterator _builderIterator;
|
arangodb::velocypack::ArrayIterator _builderIterator;
|
||||||
arangodb::velocypack::Builder _builder;
|
arangodb::velocypack::Builder _builder;
|
||||||
size_t _copyCounter;
|
|
||||||
size_t _lookupCounter;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
class RocksDBEdgeIndex final : public RocksDBIndex {
|
class RocksDBEdgeIndex final : public RocksDBIndex {
|
||||||
|
|
|
@ -80,8 +80,8 @@ class WALParser : public rocksdb::WriteBatch::Handler {
|
||||||
_includeSystem(includeSystem),
|
_includeSystem(includeSystem),
|
||||||
_onlyCollectionId(collectionId),
|
_onlyCollectionId(collectionId),
|
||||||
_builder(builder),
|
_builder(builder),
|
||||||
_currentSequence(0)
|
_startSequence(0),
|
||||||
{}
|
_currentSequence(0) {}
|
||||||
|
|
||||||
void LogData(rocksdb::Slice const& blob) override {
|
void LogData(rocksdb::Slice const& blob) override {
|
||||||
RocksDBLogType type = RocksDBLogValue::type(blob);
|
RocksDBLogType type = RocksDBLogValue::type(blob);
|
||||||
|
|
|
@ -439,15 +439,7 @@ void RocksDBRestReplicationHandler::handleCommandBatch() {
|
||||||
|
|
||||||
_vocbase->updateReplicationClient(serverId, ctx->lastTick());
|
_vocbase->updateReplicationClient(serverId, ctx->lastTick());
|
||||||
|
|
||||||
// now extend the blocker
|
resetResponse(rest::ResponseCode::NO_CONTENT);
|
||||||
// StorageEngine* engine = EngineSelectorFeature::ENGINE;
|
|
||||||
// res = engine->extendCompactionBlocker(_vocbase, id, expires);
|
|
||||||
|
|
||||||
if (res == TRI_ERROR_NO_ERROR) {
|
|
||||||
resetResponse(rest::ResponseCode::NO_CONTENT);
|
|
||||||
} else {
|
|
||||||
generateError(GeneralResponse::responseCode(res), res);
|
|
||||||
}
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue