Fix option for diff executable: allow plain names, use "" as default
ClosedPublic

Authored by kossebau on Apr 26 2019, 6:05 PM.

Details

Summary

Code in libkomparediff & kompare assumes that m_diffProgram.isEmpty()
means default, so setting an explicit "diff" on "Defaults" button click
screwed that.
Even more did QUrl::fromLocalFile/QUrl::toLocalFile not play well for
people just entering the straight name of the executable without a path.

Test Plan

Tested with copies of diff exectuable in custom paths, either given with
fill path or just by name as found in PATH, also after program restarts.
Resetting to Defaults also works as expected.

Diff Detail

Repository
R454 Kompare
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
kossebau requested review of this revision.Apr 26 2019, 6:05 PM
kossebau created this revision.
krop accepted this revision.Apr 26 2019, 6:19 PM

tested successfully with & without program and when using the 'default' button.

This revision is now accepted and ready to land.Apr 26 2019, 6:19 PM
This revision was automatically updated to reflect the committed changes.