Skip to content
Commit 4ab4219d authored by Igor Kushnir's avatar Igor Kushnir
Browse files

Don't crash when there is no documentation for a given URL

DocumentationController::showDocumentation() passes its argument to
DocumentationView::showDocumentation(), which expects it to be non-null.

Crashes could be reproduced by following any external website link or a
mailto link on a Man Page or QtHelp page in Documentation tool view.

A crash could also be reproduced with the following steps:
* copy qtgui.qch into an empty directory /tmp/test-kdev;
* open {Configure KDevelop -> Documentation -> Qt Help} page;
* uncheck "Load Qt API documentation" checkbox;
* enter /tmp/test-kdev into "Load QtHelp files from directory" field;
* press OK to save settings;
* open Qt GUI main page in Documentation tool view;
* click on a link that leads to a page in a Qt module other than Qt GUI,
  e.g. "qmake".

This commit fixes 9f1f63fa. When no
documentation provider supports a link, ManPageModel and
QtHelpProviderAbstract fall back to their respective ways of handling
unsupported links from before that commit.

Remove unused include from manpagemodel.h.
parent 0570133b
Pipeline #18720 failed with stage
in 4 minutes and 32 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