Skip to content

Commit

Permalink
ControlDoublePrivate: change warnings to debug assertions
Browse files Browse the repository at this point in the history
  • Loading branch information
Be-ing committed Oct 22, 2021
1 parent 625cebd commit cb0888f
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/control/control.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -109,14 +109,12 @@ void ControlDoublePrivate::insertAlias(const ConfigKey& alias, const ConfigKey&
MMutexLocker locker(&s_qCOHashMutex);

auto it = s_qCOHash.constFind(key);
if (it == s_qCOHash.constEnd()) {
qWarning() << "WARNING: ControlDoublePrivate::insertAlias called for null control" << key;
VERIFY_OR_DEBUG_ASSERT(it != s_qCOHash.constEnd()) {
return;
}

QSharedPointer<ControlDoublePrivate> pControl = it.value();
if (pControl.isNull()) {
qWarning() << "WARNING: ControlDoublePrivate::insertAlias called for expired control" << key;
VERIFY_OR_DEBUG_ASSERT(!pControl.isNull()) {
return;
}

Expand Down

0 comments on commit cb0888f

Please sign in to comment.