Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-27564

[REG 7.0 -> 8.0] CMakeProjectManager crashes when configuring fails

    XMLWordPrintable

Details

    • Windows
    • f58a25b60a (qt-creator/qt-creator/master)

    Description

      If I open a CMakeLists.txt-based project which fails to configure (due to any kind of error), Qt Creator crashes.

      CMakeProcess::lastExitCode() is called on a 0-pointer. Usage after destruction?

      The inferior stopped because it triggered an exception.
      Stopped in thread 0 by: Exception at 0x7ff81b13877b, code: 0xc0000005: read access violation at: 0x58, flags=0x0 (first chance).

      000000bb`65958730 00007ff8`1b12ecc6 CMakeProjectManager!CMakeProjectManager::Internal::CMakeProcess::lastExitCode(void)+0xb [C:\Users\alportal\dev\qt-creator-qt6\src\plugins\cmakeprojectmanager\cmakeprocess.h @ 63]
      000000bb`65958740 00007ff8`1b137b07 CMakeProjectManager!CMakeProjectManager::Internal::FileApiReader::cmakeFinishedState(void)+0x106 [C:\Users\alportal\dev\qt-creator-qt6\src\plugins\cmakeprojectmanager\fileapireader.cpp @ 379]
      000000bb`65958850 00007ff8`1b1333b8 CMakeProjectManager!QtPrivate::FunctorCall<QtPrivate::IndexesList<>,QtPrivate::List<>,void,void (<function> * f = 0x00007ff8`1aeca9fc, class CMakeProjectManager::Internal::FileApiReader * o = 0x00000262`d90fee48, void ** arg = 0x000000bb`659589b8)+0x27 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobjectdefs_impl.h @ 171]
      000000bb`65958890 00007ff8`1b138542 CMakeProjectManager!QtPrivate::FunctionPointer<void (<function> * f = 0x00007ff8`1aeca9fc, class CMakeProjectManager::Internal::FileApiReader * o = 0x00000262`d90fee48, void ** arg = 0x000000bb`659589b8)+0x28 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobjectdefs_impl.h @ 209]
      000000bb`659588c0 00007ff8`20470a73 CMakeProjectManager!QtPrivate::QSlotObject<void (int which = 0n1, class QtPrivate::QSlotObjectBase * this_ = 0x00000262`d8f21aa0, class QObject * r = 0x00000262`d90fee48, void ** a = 0x000000bb`659589b8, bool * ret = 0x00000000`00000000)+0x82 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobjectdefs_impl.h @ 420]
      000000bb`65958910 00007ff8`20515328 Qt6Cored!QtPrivate::QSlotObjectBase::call(class QObject * r = 0x00000262`d90fee48, void ** a = 0x000000bb`659589b8)+0x43 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobjectdefs_impl.h @ 399]
      000000bb`65958960 00007ff8`204fc8d8 Qt6Cored!doActivate<0>(class QObject * sender = 0x00000262`d4244370, int signal_index = 0n4, void ** argv = 0x000000bb`659589b8)+0x908 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobject.cpp @ 4192]
      000000bb`65958c40 00007ff8`1aeed985 Qt6Cored!QMetaObject::activate(class QObject * sender = 0x00000262`d4244370, struct QMetaObject * m = 0x00007ff8`1b19b5d0, int local_signal_index = 0n1, void ** argv = 0x00000000`00000000)+0x68 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobject.cpp @ 4253]
      000000bb`65958c80 00007ff8`1b033fce CMakeProjectManager!CMakeProjectManager::CMakeParser::qt_static_metacall(<Win32 error 0n87>)+0x5 [C:\Users\alportal\dev\{bf897039-f593-4428-b082-5a79aaa7beb6}\src\plugins\cmakeprojectmanager\CMakeProjectManager_autogen\EWIEGA46WW\moc_cmakeprocess.cpp @ 154]
      000000bb`65958cb0 00007ff8`1b033bdd CMakeProjectManager!CMakeProjectManager::Internal::CMakeProcess::handleProcessDone(<Win32 error 0n87>)+0x34e [C:\Users\alportal\dev\qt-creator-qt6\src\plugins\cmakeprojectmanager\cmakeprocess.cpp @ 188]
      000000bb`659590c0 00007ff8`1b0366b7 CMakeProjectManager!CMakeProjectManager::Internal::CMakeProcess::stop(void)+0x9d [C:\Users\alportal\dev\qt-creator-qt6\src\plugins\cmakeprojectmanager\cmakeprocess.cpp @ 156]
      000000bb`65959120 00007ff8`1b0356b8 CMakeProjectManager!QtPrivate::FunctorCall<QtPrivate::IndexesList<>,QtPrivate::List<>,void,void (<function> * f = 0x00007ff8`1aec18a2, class CMakeProjectManager::Internal::CMakeProcess * o = 0x00000262`d4244370, void ** arg = 0x000000bb`65959288)+0x27 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobjectdefs_impl.h @ 171]
      000000bb`65959160 00007ff8`1aeef222 CMakeProjectManager!QtPrivate::FunctionPointer<void (<function> * f = 0x00007ff8`1aec18a2, class CMakeProjectManager::Internal::CMakeProcess * o = 0x00000262`d4244370, void ** arg = 0x000000bb`65959288)+0x28 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobjectdefs_impl.h @ 209]
      000000bb`65959190 00007ff8`20470a73 CMakeProjectManager!QtPrivate::QSlotObject<void (int which = 0n1, class QtPrivate::QSlotObjectBase * this_ = 0x00000262`d8f59080, class QObject * r = 0x00000262`d4244370, void ** a = 0x000000bb`65959288, bool * ret = 0x00000000`00000000)+0x82 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobjectdefs_impl.h @ 420]
      000000bb`659591e0 00007ff8`20515328 Qt6Cored!QtPrivate::QSlotObjectBase::call(class QObject * r = 0x00000262`d4244370, void ** a = 0x000000bb`65959288)+0x43 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobjectdefs_impl.h @ 399]
      000000bb`65959230 00007ff8`204fc8d8 Qt6Cored!doActivate<0>(class QObject * sender = 0x00000262`d8eeaa80, int signal_index = 0n5, void ** argv = 0x000000bb`65959288)+0x908 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobject.cpp @ 4192]
      000000bb`65959510 00007ff8`2089e964 Qt6Cored!QMetaObject::activate(class QObject * sender = 0x00000262`d8eeaa80, struct QMetaObject * m = 0x00007ff8`20de98e0, int local_signal_index = 0n2, void ** argv = 0x00000000`00000000)+0x68 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\kernel\qobject.cpp @ 4253]
      000000bb`65959550 00007ff8`2089f461 Qt6Cored!QFutureWatcherBase::canceled(void)+0x24 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\Core_autogen\include\moc_qfuturewatcher.cpp @ 320]
      000000bb`65959580 00007ff8`2089e8b8 Qt6Cored!QFutureWatcherBasePrivate::sendCallOutEvent(class QFutureCallOutEvent * event = 0x00000262`d8f53550)+0x91 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\thread\qfuturewatcher.cpp @ 534]
      000000bb`659595e0 00007ff8`22b4e77b Qt6Cored!QFutureWatcherBase::event(class QEvent * event = 0x00000262`d8f53550)+0x48 [C:\Users\alportal\dev\qt6_desktop\qtbase\src\corelib\thread\qfuturewatcher.cpp @ 429]
      000000bb`65959620 00007ff8`22b4ba5a Qt6Widgetsd!QApplicationPrivate::notify_helper(class QObject * receiver = 0x00000262`d8eeaa80, class QEvent * e = 0x00000262`d8f53550)+0x1ab [C:\Users\alportal\dev\qt6_desktop\qtbase\src\widgets\kernel\qapplication.cpp @ 3341]
      [...]

      It appears to have been introduced by https://codereview.qt-project.org/c/qt-creator/qt-creator/+/411357
      Reverting the commit makes the crash disappear.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            cadam Cristian Adam
            portale Alessandro Portale
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes