Commit 7e3a4231 authored by Alexander Lohnau's avatar Alexander Lohnau 💬
Browse files

locations runner: Fix absolute filepath + arguments

The KUriFilter would interpret this as a path and consequently
produce a result.

BUG: 433053
FIXED-IN: 5.21
parent 06321a7b
...@@ -52,7 +52,8 @@ LocationsRunner::~LocationsRunner() ...@@ -52,7 +52,8 @@ LocationsRunner::~LocationsRunner()
void LocationsRunner::match(Plasma::RunnerContext &context) void LocationsRunner::match(Plasma::RunnerContext &context)
{ {
QString term = context.query(); QString term = context.query();
QFileInfo tmpInfo(KShell::tildeExpand(term)); // If we have a query with an executable and optionally arguments, BUG: 433053
QFileInfo tmpInfo(KShell::tildeExpand(KShell::splitArgs(term).constFirst()));
if (tmpInfo.isFile() && tmpInfo.isExecutable()) { if (tmpInfo.isFile() && tmpInfo.isExecutable()) {
return; return;
} }
......
Supports Markdown
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