Silence code checker warning about unused std::unique_ptr::release

We don't need the pointer, as it's the same as "this", we just don't
want the event to own the object anymore.

Nevertheless, silence code checker warning about the unused return.

Amends 96ef0004111b47cec239846b169942bbc885c181.

Pick-to: 6.8
Change-Id: I6a3c73e971f1b9e10f5754018a1fa5941dca6172
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
(cherry picked from commit 920a490d659836785f03d51edc11da1711ade965)
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This commit is contained in:
Volker Hilsheimer 2025-04-14 09:28:11 +02:00
parent cb199ab2aa
commit bc2f4ace0e

View File

@ -67,7 +67,7 @@ void QSingleShotTimer::timerEvent(QTimerEvent *event)
{
if (event->id() == Qt::TimerId::Invalid) {
StartTimerEvent *startTimerEvent = static_cast<StartTimerEvent *>(event);
startTimerEvent->timer.release();
Q_UNUSED(startTimerEvent->timer.release()); // it's the same as "this"
const QDeadlineTimer &deadline = startTimerEvent->deadline;
if (deadline.hasExpired()) {
timerFinished();