Bug 22790 - Inconsistent encoding of methods
Summary: Inconsistent encoding of methods
Status: RESOLVED WORKSFORME
Alias: None
Product: Slide
Classification: Unclassified
Component: WebDAV client (show other bugs)
Version: Nightly
Hardware: Other other
: P3 normal (vote)
Target Milestone: ---
Assignee: Slide Developer List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-08-28 14:43 UTC by Steve Vaughan
Modified: 2004-11-16 19:05 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Steve Vaughan 2003-08-28 14:43:12 UTC
Some methods (GET, HEAD, and PUT) perform path encoding, while all other methods
do not.  The constrcutor for the encoding methods looks like:

   super(URLUtil.URLEncode(path, "UTF-8"));

while all other methods look like:

   super (path);

All methods should be either encoded or decoded in order to ensure that double
encoding doesn't take place.  This problem will only be visible when attempting
to operate on resource which require encoding (i.e. there is a space in the
name).  Given that list() returns the child names unencoded, I would think it
would make the most sense to always expect unencoded paths.
Comment 1 Ingo Brunberg 2003-08-28 15:44:47 UTC
That's why these classes are marked as deprecated.

Note that their superclasses (from Commons-Httpclient), that you should use
instead, don't perform any additional encoding.
Comment 2 Steve Vaughan 2003-09-29 15:39:06 UTC
Your right, I hadn't noticed those methods were deprecated.