Quantcast
Channel: Qt DevNet forums: Qt Quick 1283365070**
Viewing all articles
Browse latest Browse all 4972

SIGSEGV error during memory deallocation in QQuickItem destructor

$
0
0
We are running into problems using QtQuick 2.0 on Qt 5.0.1 and 5.0.2. Our program have been ported from Qt4/QtQuick 1.1 and was running without problems since one year and a half. We are using QML in conjunction with C++. The program manages a Playlist of contents. Each of them are described in QML. The program dynamically creates some QQuickItem from C++ and adds them to the QML elements tree. They are correctly displayed. When a content is no more needed to be displayed, it is removed (the C++ program then calls the deleteLater() method on the QQuickItem). In the event loop, Qt destroys the QQuickItem. But from times to times (after 2 or 3 minutes of execution), the program crashes on the QQuickItem destructor. It seems that something goes wrong with elements properties deallocation in the Qt code. We track this problem during one week and find that the more deleteLater() we execute the soon the program crashes. Is there something else to do when doing a deleteLater() (we already try to do a setParent(NULL) and even a setParentItem(NULL) before but without success). Thanks in advance. Roger Here is a stack trace when the problem occures (the crash is in the Thread #1): Thread 1 (Thread 0xb4aa3700 (LWP 2071)): #0 0xb640bf70 in ?? () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5V8.so.5 No symbol table info available. #1 0xb638b73e in v8::V8::DisposeGlobal(v8::internal::Object**) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5V8.so.5 No symbol table info available. #2 0xb7aa7cb9 in QQmlVMEMetaObject::~QQmlVMEMetaObject() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Qml.so.5 No symbol table info available. #3 0xb7aa8062 in QQmlVMEMetaObject::~QQmlVMEMetaObject() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Qml.so.5 No symbol table info available. #4 0xb7a874e3 in ?? () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Qml.so.5 No symbol table info available. #5 0xb6c865c1 in QObjectPrivate::~QObjectPrivate() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #6 0xb7da5a9c in QQuickItemPrivate::~QQuickItemPrivate() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Quick.so.5 No symbol table info available. #7 0xb7da5ad2 in QQuickItemPrivate::~QQuickItemPrivate() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Quick.so.5 No symbol table info available. #8 0xb6c8bc7b in QObject::~QObject() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #9 0xb7da8861 in QQuickItem::~QQuickItem() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Quick.so.5 No symbol table info available. #10 0×0808844a in WidgetItem::~WidgetItem (this=0×8c35270, __in_chrg=<optimized out>) at ../NeoPlayer/widgetitem.cpp:10 No locals. #11 0×080683fd in QQmlPrivate::QQmlElement<WidgetItem>::~QQmlElement (this=0×8c35270, __in_chrg=<optimized out>) at /opt/Qt5.0.2/5.0.2/gcc/include/QtQml/qqmlprivate.h:91 No locals. #12 0×0806845b in QQmlPrivate::QQmlElement<WidgetItem>::~QQmlElement (this=0×8c35270, __in_chrg=<optimized out>) at /opt/Qt5.0.2/5.0.2/gcc/include/QtQml/qqmlprivate.h:91 No locals. #13 0xb6c85043 in qDeleteInEventHandler(QObject*) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #14 0xb6c86d28 in QObject::event(QEvent*) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #15 0xb7d9d689 in QQuickItem::event(QEvent*) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Quick.so.5 No symbol table info available. #16 0xb74f6f84 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Widgets.so.5 No symbol table info available. #17 0xb74fa994 in QApplication::notify(QObject*, QEvent*) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Widgets.so.5 No symbol table info available. #18 0xb6c5cafe in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #19 0xb6c5ecc4 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #20 0xb6c5f21c in QCoreApplication::sendPostedEvents(QObject*, int) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #21 0xb6ca9f14 in ?? () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #22 0xb61b7d86 in g_main_context_dispatch () from /lib/i386-linux-gnu/libglib-2.0.so.0 No symbol table info available. #23 0xb61b8125 in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0 No symbol table info available. #24 0xb61b8201 in g_main_context_iteration () from /lib/i386-linux-gnu/libglib-2.0.so.0 No symbol table info available. #25 0xb6caa328 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #26 0xb4840bb6 in ?? () from /opt/Qt5.0.2/5.0.2/gcc/plugins/platforms/libqxcb.so No symbol table info available. #27 0xb6c5b336 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #28 0xb6c5b774 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #29 0xb6c5f2c2 in QCoreApplication::exec() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Core.so.5 No symbol table info available. #30 0xb6f12334 in QGuiApplication::exec() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Gui.so.5 No symbol table info available. #31 0xb74f2124 in QApplication::exec() () from /opt/Qt5.0.2/5.0.2/gcc/lib/libQt5Widgets.so.5 No symbol table info available. #32 0×080583e3 in main (argc=2, argv=0xbffff684) at ../NeoPlayer/main.cpp:315

Viewing all articles
Browse latest Browse all 4972

Trending Articles