HomeScreen: Unexpected deferred delete
Description
Environment
Attachments
Activity
Walt Miner September 25, 2018 at 1:31 PM
Will close for FF 6.0.0 and if another issue crops up please create a new ticket.

Tadao Tanikawa September 25, 2018 at 5:06 AM
Issue about crushing is resolved by this patch.
But I am not sure what happens after MessageEngine.onDisconnected() and what is expected originally. Memory leak? Another issue will be around network connection? And I also mention why original code wants to free m_websocket explicitly.
If we don't need anything more when onDisconnected() , this ticket can be closed.

Matt Ranostay September 25, 2018 at 2:35 AM
Pretty sure I read this as the current patchset fixed the issue.
Walt Miner September 24, 2018 at 4:39 PM
Is another patch required or can this be resolved?

Tadao Tanikawa September 24, 2018 at 2:49 AM
This was a simple bug.
m_websocket is defined inside MessageEngine class and it is not pointer, so it cannot be delete.
The following is a log when this issue was reproduced. It seems that 3 MessageEngine were alwayls created.
If MessageEngine::onDisconnected() was called, an illegal free was always happened.
On my side, this is frequently happened with internet connection, and never happened without network connection.
On rcar-m3, agl-demo-platform configured with agl-demo and agl-devel, HomeScreen frequently crushes at booting by abort() of double free.
On upsquared with FF.rc6, this can be observed for every boot.
This is triggered by unexpected deferred delete in Qt.
Here is backtrace of HomeScreen:
QEvent::DeferredDelete dispatched