Skip to content

KFileItem: add exists() function and use it in KCoreDirLister

Méven Car requested to merge work/meven/kcoredirlister-remove-file into master

Until now processPendingUpdates did not remove files. It relied on subsequent updates to the parent dir to remove it. But this is racy, when a file is touched its parent is added to pendingDirectoryUpdates, but if a file is removed as its parent dir is updated, no further updateDirectory will be called, and the file removal get unnoticed.

Since we already did a stat to check for file attribute changes, we can also make sure in processPendingUpdates whether a file was removed and act accordingly.

CCBUG: 244163

Context: https://discuss.kde.org/t/dolphin-doesnt-update-its-view-unless-i-press-f5/5311/19

The provided test scenario shows that it solved the issue.

Edited by Méven Car

Merge request reports