refactor: Make move semantics explicit for callers

This commit is contained in:
Hennadii Stepanov 2023-03-21 13:04:01 +00:00
parent 6c2d5972f3
commit 04831fee6d
No known key found for this signature in database
GPG key ID: 410108112E7EA81F
6 changed files with 16 additions and 15 deletions

View file

@ -166,7 +166,7 @@ public:
}
//! Add a batch of checks to the queue
void Add(std::vector<T>& vChecks) EXCLUSIVE_LOCKS_REQUIRED(!m_mutex)
void Add(std::vector<T>&& vChecks) EXCLUSIVE_LOCKS_REQUIRED(!m_mutex)
{
if (vChecks.empty()) {
return;
@ -237,10 +237,11 @@ public:
return fRet;
}
void Add(std::vector<T>& vChecks)
void Add(std::vector<T>&& vChecks)
{
if (pqueue != nullptr)
pqueue->Add(vChecks);
if (pqueue != nullptr) {
pqueue->Add(std::move(vChecks));
}
}
~CCheckQueueControl()