run: fix "couldn't find executable" for the existing executables

Fixes: #1672
This commit is contained in:
Evgeny Vereshchagin
2015-10-25 18:29:24 +00:00
parent f739078599
commit 9dae55f4bb
-5
View File
@@ -1162,11 +1162,6 @@ int main(int argc, char* argv[]) {
log_error_errno(r, "Failed to find executable %s: %m", argv[optind]);
goto finish;
}
if (r == 0) {
log_error("Couldn't find executable %s.", argv[optind]);
r = -ENOENT;
goto finish;
}
argv[optind] = command;
}