Skip to content

Commit b93d9dc

Browse files
committed
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 96ef000. Change-Id: I6a3c73e971f1b9e10f5754018a1fa5941dca6172 Reviewed-by: Axel Spoerl <[email protected]> (cherry picked from commit 920a490) Reviewed-by: Volker Hilsheimer <[email protected]> (cherry picked from commit bc2f4ac) Reviewed-by: Qt Cherry-pick Bot <[email protected]>
1 parent 983bb1f commit b93d9dc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/corelib/kernel/qsingleshottimer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ void QSingleShotTimer::timerEvent(QTimerEvent *event)
7676
{
7777
if (event->id() == Qt::TimerId::Invalid) {
7878
StartTimerEvent *startTimerEvent = static_cast<StartTimerEvent *>(event);
79-
startTimerEvent->timer.release();
79+
Q_UNUSED(startTimerEvent->timer.release()); // it's the same as "this"
8080
const QDeadlineTimer &deadline = startTimerEvent->deadline;
8181
if (deadline.hasExpired()) {
8282
timerFinished();

0 commit comments

Comments
 (0)