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

David Redondo <k...@david-redondo.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|CONFIRMED                   |RESOLVED
         Resolution|---                         |DOWNSTREAM

--- Comment #4 from David Redondo <k...@david-redondo.de> ---
I would say this is a wireshark bug.  It calls exit() instead of letting main
finish, this skips the QApplication destructor. 
The reason this crashes only on breeze is that it deleteLater the animation
data of widgets. Destroying animation data accesses the static thread_local 
animation timer. 
When doing exit() this thread local is destroyed then the thread exit handler
called which processes DeferredDeleteEvents a final time. Destroying the
animation object tries to access the deleted static animation timer. 

Minimal reproducer:

#include <QApplication>
#include <QPushButton>
int main(int argc, char**argv)
{
    QApplication app(argc, argv);
    auto window = new QWidget;
    auto button = new QPushButton(window);
    QObject::connect(button, &QPushButton::clicked, &QCoreApplication::quit);
    window->show();
    app.exec();
    delete window;
    exit(0);
}

Clicking on the button crashes. 
The warnings like QThreadStorage: Thread 0x5020000060d0 exited after
QThreadStorage 10 destroyed when closing via window decoration have the same
reason. 

Wireshark just needs to return normally from main and let the QAppliciation
destructor run to fix this. 

(Sidenote exiting while the app is running seems to be fine, just exiting when
exec has already returned seems to be weird dont do this territory)

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

Reply via email to