Summary: | Konqueror removes symlinks on directories recursively | ||
---|---|---|---|
Product: | [Unmaintained] kio | Reporter: | Candid Dauth <cdauth+bugs.kde.org> |
Component: | ftp | Assignee: | David Faure <faure> |
Status: | RESOLVED FIXED | ||
Severity: | major | ||
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | openSUSE | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Candid Dauth
2005-07-16 19:20:03 UTC
Data loss -> raising severity. Ouch, sorry for the data loss. This shouldn't happen, obviously. Can you tell me which konqueror view mode you were using? Icon view, detailed list view, or tree view? The protocol used was FTP, right? Yep, the protocol was FTP, the view mode was icon view. Can confirm with 3.5.5 Looking into kioslave/ftp/ftp.cc I find some comments on this, e.g.: // Links on ftp sites are often links to dirs, and we have no way to check // that. Let's do like Netscape : assume dirs generally. // But we do this only when the mimetype can't be known from the filename. // --> we do better than Netscape :-) I have no idea but maybe this is the reason for this "bug" and maybe it can not be done better ? Hope David Faure can comment on this. SVN commit 871146 by dfaure: Fix grave kio bug with FTP: if you delete a symlink to a folder, it would recursively delete the folder (!) Sounds stupid, but it's FTP which is stupid; the only way to know if something is a link is by listing its parent dir, but this isn't always possible (if no permission to list the parent dir)... -> the URL isn't enough info, we need the KFileItem from the listing. Rather than adding KIO::del(KFileItemList) (and porting a lot of code), I simply grab the KFileItem from KDirListerCache, as discussed with Michael Brade in 2006 for other reasons. As a side effect, this speeds up deletion (again!) in the case of remote protocols (saves a KIO::stat per toplevel item to delete). BUG: 109181 M +13 -0 deletejob.cpp M +15 -2 kdirlister.cpp M +13 -1 kdirlister.h WebSVN link: http://websvn.kde.org/?view=rev&revision=871146 |