DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39220>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39220

           Summary: Missing body in a PROPFIND request
           Product: Slide
           Version: 2.1
          Platform: Other
        OS/Version: Windows XP
            Status: NEW
          Severity: major
          Priority: P2
         Component: WebDAV client
        AssignedTo: slide-dev@jakarta.apache.org
        ReportedBy: [EMAIL PROTECTED]


1. Invocations of the setHttpURL() method made from constructors lead to 
generation of a PROPFIND request with a missing body. Moreover, the "Content-
Type" header is not set for that request as well. As a result, a WebdavResource 
constructor throws an exception: 

    public void test() throws Exception {
        HttpURL url = new HttpURL("http://localhost:8080/slide/";);
        WebdavResource webdav = new WebdavResource(url, 1, true);
    }

generates (Apache Tomcat/5.5.9)

PROPFIND /slide/ HTTP/1.1
Content-Type: text/xml; charset=utf-8
User-Agent: Jakarta Commons-HttpClient/3.0
Host: 127.0.0.1:8081
Depth: 1

which leads to

org.apache.commons.httpclient.HttpException
        at org.apache.webdav.lib.WebdavResource.propfindMethod(WebdavResource.
java:3467)
        at org.apache.webdav.lib.WebdavResource.propfindMethod(WebdavResource.
java:3423)
        at 
org.apache.webdav.lib.WebdavResource.setNamedProp(WebdavResource.java:
967)
        at 
org.apache.webdav.lib.WebdavResource.setBasicProperties(WebdavResource.
java:912)
        at 
org.apache.webdav.lib.WebdavResource.setProperties(WebdavResource.java:
1894)
        at org.apache.webdav.lib.WebdavResource.setHttpURL(WebdavResource.java:
1301)
        at org.apache.webdav.lib.WebdavResource.<init>(WebdavResource.java:275)


because of

HTTP/1.1 400 Bad Request: Request content missing
Server: Apache-Coyote/1.1
Set-Cookie: JSESSIONID=7006BD8F1AE1863B56B86D1C79276E8D; Path=/slide
Content-Type: text/html;charset=utf-8
Content-Length: 1077
Date: Thu, 06 Apr 2006 08:50:30 GMT
Connection: close


2. There is a typo in a constructor (there should not be "this." prefix!)

public WebdavResource(HttpURL httpURL, int action, int depth,             
boolean followRedirects)throws HttpException, IOException {
       
    setFollowRedirects(this.followRedirects);

}

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to