[prev in list] [next in list] [prev in thread] [next in thread] 

List:       slide-dev
Subject:    Bug in WebdavResource.setWebdavProperties(Enumeration responses)
From:       Willem Voogd <w.f.voogd () planet ! nl>
Date:       2006-06-28 15:21:22
Message-ID: 44A29E72.8060203 () planet ! nl
[Download RAW message or body]

Hi,

this is my first post here, so if i'm posting in the wrong place, tell me!

I'm using the slide client library to communicate with MS Exchange, 
which works fine, except for calendar items which were made using the 
outlook web access.
These items get a name like {0123-4567-8901-2345}.EML. When i call the 
WebdavResource.getChildResource() method, i got an error: 
org.apache.commons.httpclient.URIException: escaped absolute path not valid

To get around this i modified the setWebdavProperties method to escape 
the braces:

                href = href.replaceAll("\\{", "%7B");
                href = href.replaceAll("\\}", "%7D");

before assigning the childURI (unmodified):

                char[] childURI = (myURI + (myURI.endsWith("/") ? "" : "/")
                                   + URIUtil.getName(href)).toCharArray();

and then it worked.

Now i know this is a very nasty hack, only scratching my own personal 
little itch, but i would like to put in some more effort to make a nice 
patch, so then maybe i can contribute it in the upstream, maybe for the 
2.2 release.

My question is whether someone could give me some pointers on where to 
look to make href an escaped String, or whether href is assumed to 
already be an escaped String and this is just an Exchange problem, in 
listing non-escaped filenames instead of escaped ones?

TIA & Cheers,

Willem

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-dev-help@jakarta.apache.org

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic