diff --git a/cfg/qt.cfg b/cfg/qt.cfg index 66f6e78b3b6..c7bf3d8779b 100644 --- a/cfg/qt.cfg +++ b/cfg/qt.cfg @@ -410,7 +410,6 @@ - diff --git a/test/cfg/qt.cpp b/test/cfg/qt.cpp index 78827d3583c..2b683648dcd 100644 --- a/test/cfg/qt.cpp +++ b/test/cfg/qt.cpp @@ -33,6 +33,7 @@ #include #include #include +#include // TODO: this is actually available via Core5Compat but I could not get it to work with pkg-config #if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) @@ -892,3 +893,13 @@ int qdateIsValid() Q_ASSERT(qd.isValid()); // Should not warn here with assertWithSideEffect return qd.month(); } + +struct S_QTimer_connect : QObject { // #13846 + S_QTimer_connect() { + // cppcheck-suppress checkLibraryFunction - timeout() is a signal from QTimer + QObject::connect(&timer, SIGNAL(timeout()), this, SLOT(update())); + } + QTimer timer; +private slots: + bool update(); +};