Bug 331295

Summary: KIO::http_delete always adds a trailing slash to the url
Product: [Frameworks and Libraries] kio Reporter: Andrea Iacovitti <aiacovitti>
Component: httpAssignee: kdelibs bugs <kdelibs-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: adawit
Priority: NOR    
Version: 4.12.60   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In: 4.12.4

Description Andrea Iacovitti 2014-02-19 15:08:51 UTC
KIO::http_delete always adds a trailing slash to the specified url,
e.g. the code:
KUrl url("http://localhost/deleteme.html");
KIO::TransferJob *job = KIO::http_delete(url, KIO::HideProgressInfo);
results in the following http request:
"DELETE /deleteme.html/"

It seems the culprit of the issue is commit
http://commits.kde.org/kdelibs/58294ac
Comment 1 Dawit Alemayehu 2014-02-27 01:23:41 UTC
That is because KIO::http_delete itself does not send the information about whether or not the requested resource is a file or a directory and I do not think it can do so easily ; so we have to find some sort of solution for the webdav related problem.
Comment 2 Dawit Alemayehu 2014-03-08 21:42:37 UTC
Git commit e90577d4903d2c1b7a35e4a18efe3544132fbb57 by Dawit Alemayehu.
Committed on 27/02/2014 at 14:14.
Pushed by adawit into branch 'KDE/4.12'.

Correctly handle deletion of directories for http/webdav protocols.

Reverts http://commits.kde.org/kdelibs/58294ac.
FIXED-IN: 4.12.4
REVIEW: 116122

M  +9    -2    kio/kio/deletejob.cpp
M  +1    -5    kioslave/http/http.cpp

http://commits.kde.org/kdelibs/e90577d4903d2c1b7a35e4a18efe3544132fbb57
Comment 3 Dawit Alemayehu 2014-03-08 22:02:45 UTC
Git commit 1bdb286f62454bb13cc299abd45a297a56b45cea by Dawit Alemayehu.
Committed on 08/03/2014 at 22:00.
Pushed by adawit into branch 'master'.

Forward port:

Correctly handle deletion of directories for http/webdav protocols.

Reverts http://commits.kde.org/kdelibs/58294ac.
FIXED-IN: 4.12.4
REVIEW: 116122

M  +11   -2    src/core/deletejob.cpp
M  +1    -6    src/ioslaves/http/http.cpp

http://commits.kde.org/kio/1bdb286f62454bb13cc299abd45a297a56b45cea