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

            Bug ID: 400272
           Summary: Dolphin crashes on startup on invalid XML config file
           Product: dolphin
           Version: 18.08.2
          Platform: Other
                OS: Linux
            Status: REPORTED
          Severity: crash
          Priority: NOR
         Component: general
          Assignee: dolphin-bugs-n...@kde.org
          Reporter: bus_kdezi...@semitwist.com
                CC: elvis.angelac...@kde.org
  Target Milestone: ---

I was unable to fix the status of Bug 400093 so I'm continuing it here.

The basic problem is that Dolphin immediately crashes upon startup if
~/.local/share/kxmlgui5/dolphin/dolphinui.rc is malformed. According to Elvis
Angelaccio, this is due to a limitation in kxmlgui. I have filed a
corresponding issue for kxmlgui: Bug 400271

Replying to Elvis Angelaccio's message from Bug 400093:

"There is an abort() in kxmlgui if the xml file has a wrong syntax."

If that's true, then that's clearly a major shortcoming of kxmlgui. In this
case, the correct course of action is not to mark this a non-bug, but rather to
open an issue for kxmlgui to support optionally dealing with bad XML in a way
other than crashing the entire application (see below) and to mark that issue
as blocking this one.


"There is nothing we can do to prevent the crash, as that file is used to build
the whole GUI and must be correct."

That is clearly not true. For example, kxmlgui can first be fixed to add
optional support for handling bad XML in a way other than crashing, after
which, Dolphin can be fixed to do any one or more of the following (and these
are just off the top of my head):

A. Present a dialog informing the user that
~/.local/share/kxmlgui5/dolphin/dolphinui.rc is malformed. Maybe even show some
basic information about the error, such as line number. So the user actually
knows what went wrong and why, and at least has some hope of doing something
about it, rather than being left with what appears to be (and may as well be,
from their perspective) a fatally broken piece of software.

B. Start Dolphin anyway, using the default configuration Dolphin already uses
when no dolphinui.rc is found. So the user can at least still use the
application if they need to.

C. (Maybe) Rename the corrupted dolphinui.rc to a backup name, so it doesn't
continue to cause problems.

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

Reply via email to