Skip to content
Commit 1a599050 authored by Akseli Lahtinen's avatar Akseli Lahtinen
Browse files

terminalpanel.cpp: Set m_konsolePart to nullptr during exit signal

If Dolphin terminal is open, and one types `exit` there and then closes Dolphin, Dolphin crashes due to a dangling pointer.

Konsole KPart is deleting itself when Konsole session exits, but Dolphin tracks it as a child of the Terminal Panel. 
The Terminal Panel doesn't get destroyed when Konsole KPart does, and it tries to double free during children clean up.
(Thanks @sitter !) 

Setting `m_konsolePart` to `nullptr` during exit signal fixes this, since there is already check in place for that in the destructor.

BUG:479596
parent 7e02110c
Pipeline #577843 passed with stages
in 8 minutes and 58 seconds
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment