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

--- Comment #4 from Igor Kushnir <[email protected]> ---
I spent some time debugging the crash when running `open! / /path/to/some/file`
in Terminal tool view. The bug is probably in
DocumentController::openDocumentsWithSplitSeparators(). Specifically, I suspect
that it uses the Sublime::Area::addView() API incorrectly, because this API is
widely used elsewhere without crashes. What happens is:
1. MainWindowPrivate::viewAdded() destroys the existing Sublime::Container and
creates a new one with the following code:
    ViewCreator viewCreator(this);
    area->walkViews(viewCreator, index);
2. MainWindowPrivate::ViewCreator::operator() creates a new Sublime::Container,
but replaces the value of only a single element of MainWindow::viewContainers,
leaving the values of the remaining elements pointing to the destroyed
Sublime::Container.
3. MainWindow::updateAllTabColors() dereferences the pointer to the destroyed
Sublime::Container, which causes the reported segmentation fault.

The implementation of DocumentController::openDocumentsWithSplitSeparators() is
long and convoluted. Fixing this crash properly requires understanding it, as
well as related Sublime code. I am new to this area of KDevelop and don't want
to delve deep into it at this time.

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

Reply via email to