https://bugs.kde.org/show_bug.cgi?id=520512

Nicolas Fella <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]

--- Comment #12 from Nicolas Fella <[email protected]> ---
==69976==ERROR: AddressSanitizer: heap-use-after-free on address 0x7ca49218b3c0
at pc 0x7f849f1144d3 bp 0x7ffd08a7f670 sp 0x7ffd08a7f668
READ of size 4 at 0x7ca49218b3c0 thread T0
    #0 0x7f849f1144d2 in std::__atomic_base<int>::load(std::memory_order) const
/usr/include/c++/15/bits/atomic_base.h:501
    #1 0x7f849f1144d2 in int QAtomicOps<int>::loadRelaxed<int>(std::atomic<int>
const&)
/home/nico/workspace/qt6-dev/qtbase/src/corelib/thread/qatomic_cxx11.h:203
    #2 0x7f849f1144d2 in QBasicAtomicInteger<int>::loadRelaxed() const
/home/nico/workspace/qt6-dev/qtbase/src/corelib/thread/qbasicatomic.h:37
    #3 0x7f849f1144d2 in QQmlRefCount::addref() const
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/qml/ftw/qqmlrefcount_p.h:143
    #4 0x7f849f443963 in
QQmlRefPointer<QV4::CompiledData::CompilationUnit>::operator=(QQmlRefPointer<QV4::CompiledData::CompilationUnit>
const&)
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/qml/ftw/qqmlrefcount_p.h:209
    #5 0x7f849f439549 in QV4::ExecutableCompilationUnit::clear()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsruntime/qv4executablecompilationunit.cpp:294
    #6 0x7f849f39d1d5 in QV4::ExecutionEngine::~ExecutionEngine()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsruntime/qv4engine.cpp:894
    #7 0x7f849f2ca9e6 in
std::default_delete<QV4::ExecutionEngine>::operator()(QV4::ExecutionEngine*)
const /usr/include/c++/15/bits/unique_ptr.h:92
    #8 0x7f849f2caa88 in std::unique_ptr<QV4::ExecutionEngine,
std::default_delete<QV4::ExecutionEngine> >::~unique_ptr()
/usr/include/c++/15/bits/unique_ptr.h:408
    #9 0x7f849f2c0315 in QJSEnginePrivate::~QJSEnginePrivate()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsapi/qjsengine.cpp:1271
    #10 0x7f849f2c0346 in QJSEnginePrivate::~QJSEnginePrivate()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsapi/qjsengine.cpp:1271
    #11 0x7f84975438f3 in
QScopedPointerDeleter<QObjectData>::cleanup(QObjectData*)
/home/nico/workspace/qt6-dev/qtbase/src/corelib/tools/qscopedpointer.h:25
    #12 0x7f84975438f3 in QScopedPointer<QObjectData,
QScopedPointerDeleter<QObjectData> >::~QScopedPointer()
/home/nico/workspace/qt6-dev/qtbase/src/corelib/tools/qscopedpointer.h:82
    #13 0x7f849753ec38 in QObject::~QObject()
/home/nico/workspace/qt6-dev/qtbase/src/corelib/kernel/qobject.cpp:1190
    #14 0x7f849f2bce7d in QJSEngine::~QJSEngine()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsapi/qjsengine.cpp:379
    #15 0x7f849f2bceb2 in QJSEngine::~QJSEngine()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsapi/qjsengine.cpp:379
    #16 0x7f8497536b3e in QObjectPrivate::deleteChildren()
/home/nico/workspace/qt6-dev/qtbase/src/corelib/kernel/qobject.cpp:2283
    #17 0x7f849753ece1 in QObject::~QObject()
/home/nico/workspace/qt6-dev/qtbase/src/corelib/kernel/qobject.cpp:1181
    #18 0x7b8490713798 in Scriptface::~Scriptface()
/home/nico/kde-qtdev/src/ki18n/src/i18n/ktranscript.cpp:680
    #19 0x7b84907137b3 in Scriptface::~Scriptface()
/home/nico/kde-qtdev/src/ki18n/src/i18n/ktranscript.cpp:680
    #20 0x7b8490737e65 in void qDeleteAll<QHash<QString,
Scriptface*>::const_iterator>(QHash<QString, Scriptface*>::const_iterator,
QHash<QString, Scriptface*>::const_iterator)
/home/nico/kde-qtdev/usr/include/QtCore/qalgorithms.h:25
    #21 0x7b849072ff3c in void qDeleteAll<QHash<QString, Scriptface*>
>(QHash<QString, Scriptface*> const&)
/home/nico/kde-qtdev/usr/include/QtCore/qalgorithms.h:33
    #22 0x7b8490711080 in KTranscriptImp::~KTranscriptImp()
/home/nico/kde-qtdev/src/ki18n/src/i18n/ktranscript.cpp:464
    #23 0x7b84907110d7 in KTranscriptImp::~KTranscriptImp()
/home/nico/kde-qtdev/src/ki18n/src/i18n/ktranscript.cpp:465
    #24 0x7b849073766c in
std::default_delete<KTranscriptImp>::operator()(KTranscriptImp*) const
/usr/include/c++/15/bits/unique_ptr.h:92
    #25 0x7b849072fa90 in std::unique_ptr<KTranscriptImp,
std::default_delete<KTranscriptImp> >::~unique_ptr()
/usr/include/c++/15/bits/unique_ptr.h:408
    #26 0x7b8490725965 in ~Holder
/home/nico/kde-qtdev/usr/include/QtCore/qglobalstatic.h:55
    #27 0x7f84968450df in __run_exit_handlers
/usr/src/debug/glibc-2.43/stdlib/exit.c:118
    #28 0x7f84968451cf in __GI_exit /usr/src/debug/glibc-2.43/stdlib/exit.c:148
    #29 0x7f849682b344 in __libc_start_call_main
../sysdeps/nptl/libc_start_call_main.h:83
    #30 0x7f849682b46a in __libc_start_main_impl ../csu/libc-start.c:360
    #31 0x0000004193c4 in _start ../sysdeps/x86_64/start.S:115

0x7ca49218b3c0 is located 0 bytes inside of 264-byte region
[0x7ca49218b3c0,0x7ca49218b4c8)
freed by thread T0 here:
    #0 0x7f84a332dfbf in operator delete(void*, unsigned long)
../../../../libsanitizer/asan/asan_new_delete.cpp:190
    #1 0x7f849f11feee in
QQmlRefCounted<QV4::CompiledData::CompilationUnit>::release() const
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/qml/ftw/qqmlrefcount_p.h:154
    #2 0x7f849f11ff16 in
QQmlRefPointer<QV4::CompiledData::CompilationUnit>::~QQmlRefPointer()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/qml/ftw/qqmlrefcount_p.h:200
    #3 0x7f84968450df in __run_exit_handlers
/usr/src/debug/glibc-2.43/stdlib/exit.c:118

previously allocated by thread T0 here:
    #0 0x7f84a332d0ff in operator new(unsigned long)
../../../../libsanitizer/asan/asan_new_delete.cpp:109
    #1 0x7f849f4423fe in QQmlRefPointer<QV4::CompiledData::CompilationUnit>
QQml::makeRefPointer<QV4::CompiledData::CompilationUnit>()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/qml/ftw/qqmlrefcount_p.h:124
    #2 0x7f849f4395d9 in QV4::ExecutableCompilationUnit::clear()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsruntime/qv4executablecompilationunit.cpp:293
    #3 0x7f849f39d1d5 in QV4::ExecutionEngine::~ExecutionEngine()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsruntime/qv4engine.cpp:894
    #4 0x7f849f2ca9e6 in
std::default_delete<QV4::ExecutionEngine>::operator()(QV4::ExecutionEngine*)
const /usr/include/c++/15/bits/unique_ptr.h:92
    #5 0x7f849f2caa88 in std::unique_ptr<QV4::ExecutionEngine,
std::default_delete<QV4::ExecutionEngine> >::~unique_ptr()
/usr/include/c++/15/bits/unique_ptr.h:408
    #6 0x7f849f2c0315 in QJSEnginePrivate::~QJSEnginePrivate()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsapi/qjsengine.cpp:1271
    #7 0x7f849f89cbf6 in QQmlEnginePrivate::~QQmlEnginePrivate()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/qml/qqmlengine.cpp:203
    #8 0x7f849f89ccb0 in QQmlEnginePrivate::~QQmlEnginePrivate()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/qml/qqmlengine.cpp:203
    #9 0x7f84975438f3 in
QScopedPointerDeleter<QObjectData>::cleanup(QObjectData*)
/home/nico/workspace/qt6-dev/qtbase/src/corelib/tools/qscopedpointer.h:25
    #10 0x7f84975438f3 in QScopedPointer<QObjectData,
QScopedPointerDeleter<QObjectData> >::~QScopedPointer()
/home/nico/workspace/qt6-dev/qtbase/src/corelib/tools/qscopedpointer.h:82
    #11 0x7f849753ec38 in QObject::~QObject()
/home/nico/workspace/qt6-dev/qtbase/src/corelib/kernel/qobject.cpp:1190
    #12 0x7f849f2bce7d in QJSEngine::~QJSEngine()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/jsapi/qjsengine.cpp:379
    #13 0x7f849f89cece in QQmlEngine::~QQmlEngine()
/home/nico/workspace/qt6-dev/qtdeclarative/src/qml/qml/qqmlengine.cpp:385
    #14 0x000000471b84 in void std::destroy_at<QQmlEngine>(QQmlEngine*)
/usr/include/c++/15/bits/stl_construct.h:88
    #15 0x000000471b1d in void std::_Destroy<QQmlEngine>(QQmlEngine*)
/usr/include/c++/15/bits/stl_construct.h:164
    #16 0x000000471937 in void std::allocator_traits<std::allocator<void>
>::destroy<QQmlEngine>(std::allocator<void>&, QQmlEngine*)
/usr/include/c++/15/bits/alloc_traits.h:819
    #17 0x000000471937 in std::_Sp_counted_ptr_inplace<QQmlEngine,
std::allocator<void>, (__gnu_cxx::_Lock_policy)2>::_M_dispose()
/usr/include/c++/15/bits/shared_ptr_base.h:615
    #18 0x00000046265b in
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release()
/usr/include/c++/15/bits/shared_ptr_base.h:345
    #19 0x000000464785 in
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
/usr/include/c++/15/bits/shared_ptr_base.h:1069
    #20 0x0000004638e3 in std::__shared_ptr<QQmlEngine,
(__gnu_cxx::_Lock_policy)2>::~__shared_ptr()
/usr/include/c++/15/bits/shared_ptr_base.h:1531
    #21 0x0000004638ff in std::shared_ptr<QQmlEngine>::~shared_ptr()
/usr/include/c++/15/bits/shared_ptr.h:175
    #22 0x000000463e67 in SidebarMode::Private::~Private()
/home/nico/kde-qtdev/src/systemsettings/app/SidebarMode.cpp:105
    #23 0x000000453a10 in SidebarMode::~SidebarMode()
/home/nico/kde-qtdev/src/systemsettings/app/SidebarMode.cpp:174
    #24 0x000000453a49 in SidebarMode::~SidebarMode()
/home/nico/kde-qtdev/src/systemsettings/app/SidebarMode.cpp:175
    #25 0x7f8497536b3e in QObjectPrivate::deleteChildren()
/home/nico/workspace/qt6-dev/qtbase/src/corelib/kernel/qobject.cpp:2283
    #26 0x7f849afe7e82 in QWidget::~QWidget()
/home/nico/workspace/qt6-dev/qtbase/src/widgets/kernel/qwidget.cpp:1542
    #27 0x7f849b4a62c6 in QMainWindow::~QMainWindow()
/home/nico/workspace/qt6-dev/qtbase/src/widgets/widgets/qmainwindow.cpp:292
    #28 0x7f84a2564bb4 in KMainWindow::~KMainWindow()
/home/nico/kde-qtdev/src/kxmlgui/src/kmainwindow.cpp:438
    #29 0x0000004431d1 in SettingsBase::~SettingsBase()
/home/nico/kde-qtdev/src/systemsettings/app/SettingsBase.cpp:72
    #30 0x0000004431f9 in SettingsBase::~SettingsBase()
/home/nico/kde-qtdev/src/systemsettings/app/SettingsBase.cpp:72

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to