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

--- Comment #2 from Méven <[email protected]> ---
Git commit fb5a887754b4b8daff97ef9c40f4f8e2806a19b1 by Méven Car, on behalf of
Anshul Singh.
Committed on 29/09/2026 at 12:40.
Pushed by meven into branch 'master'.

ktrash: report errors and exit non-zero on --empty/--restore failure

TrashImpl::emptyTrash() already correctly detects when a trashed item
can't be fully removed (e.g. permission-restricted or read-only
contents) and correctly leaves its .trashinfo file in place. But the
ktrash CLI that Dolphin's "Empty Trash" action invokes discarded the
job's result and unconditionally returned 0, so users saw no error and
no indication that anything had gone wrong: Dolphin's menu action
appeared to do nothing, silently.

The --restore branch had the same issue in a milder form: it already
printed job->errorString() on failure, but still fell through to an
unconditional return 0 afterward.

Both branches now check job->exec()'s result and return 1 on failure,
consistent with the existing invalid-URL error path a few lines above.
Related: bug 413360

M  +6    -3    src/kioworkers/trash/ktrash.cpp

https://invent.kde.org/frameworks/kio/-/commit/fb5a887754b4b8daff97ef9c40f4f8e2806a19b1

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

Reply via email to