| Summary: | Krusader+kio_sftp: [data loss] Deleting symlink to directory recursively deletes linked directory | ||
|---|---|---|---|
| Product: | [Applications] krusader | Reporter: | Kevin Kofler <kevin.kofler> |
| Component: | general | Assignee: | Krusader Bugs Distribution List <krusader-bugs-null> |
| Status: | RESOLVED FIXED | ||
| Severity: | critical | CC: | davide, krusader-bugs-null, simon.persson |
| Priority: | VHI | ||
| Version First Reported In: | 2.4.0-beta3 "Single Step" | ||
| Target Milestone: | --- | ||
| Platform: | Fedora RPMs | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
|
Description
Kevin Kofler
2015-04-07 12:59:51 UTC
More detailed steps to Reproduce: 1. Connect to a sftp:// share. 2. Create a directory named "test-bug345952-1". 3. Create a "test.txt" file inside "test-bug345952-1". 4. ssh into the server (creating a symlink from within Krusader is not offered over sftp). 5. ln -s test-bug345952-1 test-bug345952-2 6. Attempt to delete the directory "test-bug345952-2" from Krusader. Not only does this delete the contents of "test-bug345952-1" (the "test.txt" file you created), but it also fails to delete the symlink, claiming no such directory exists. (So this deletes stuff I DIDN'T want to delete while NOT deleting the stuff I actually wanted to delete.) This failure is suprising because Krusader correctly displays the directory as a symlink. Dolphin does the right thing, so this is not kio_sftp's fault. This behavior cannot be observed on local files though. I redid the test on a local directory, and there, only the symlink was deleted, as expected. Ping? Is anybody reading this? This is a major data loss bug, it must be addressed ASAP! CCing Davide Gianforte, who is actively working on the KF5 port (though I haven't checked whether this bug can be reproduced there, I checked it only with the kdelibs4 version). Tested this now and can confirm the bug in last released version for KDE4. Also found the bug present after straight porting to KF5/Qt5. I fixed it in commit 5ad78473c10fd339f185c5584f6fd7f03acf73d2 in the plasma branch (but this commit really has nothing to do with porting), although I did not know about this bug then. Interesting that when digging through commit history, the change that introduced the problem mentions that it was a fix for following links on sftp... It's been like that since 2004. (It could of course be there was no bug back then but that KIO has changed behaviour since then) Anyway, closing this as FIXED. Thanks for reporting! Indeed, quite an ugly one! |