put server on heap so it doesn't get dtor'd in the wrong thread

Authored by sitter on Jul 1 2019, 2:25 PM.

Description

put server on heap so it doesn't get dtor'd in the wrong thread

destroying (parented) objects causes event posting which would be happening
across threads when the server is on the stack and gets destroyed from
the main thread rather than the loop thread. simply allocate it on the
heap so it gets cleaned up along with its parenting qthread rather than
the stack unwind.

QFATAL : Bugzilla::ConnectionTest::testPut() ASSERT failure in QCoreApplication::sendEvent: "Cannot send events to objects owned by a different thread. Current thread 0x0x6020000000b0. Receiver '' (of type 'QNativeSocketEngine') was created in thread 0x0x7fffffffc420", file kernel/qcoreapplication.cpp, line 577

Details

Committed
sitterJul 1 2019, 2:25 PM
Parents
R871:150f7bd1b58b: switch platform guessing to a static hash
Branches
Unknown
Tags
Unknown