ib          2004/04/09 08:45:47

  Modified:    webdavclient/clientlib/src/java/org/apache/webdav/lib/methods
                        Tag: SLIDE_2_0_RELEASE_BRANCH
                        XMLResponseMethodBase.java
  Log:
  Apply workaround to accept Ok instead of Multistatus for ReportMethod
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.2.2.3   +10 -7     
jakarta-slide/webdavclient/clientlib/src/java/org/apache/webdav/lib/methods/XMLResponseMethodBase.java
  
  Index: XMLResponseMethodBase.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-slide/webdavclient/clientlib/src/java/org/apache/webdav/lib/methods/XMLResponseMethodBase.java,v
  retrieving revision 1.2.2.2
  retrieving revision 1.2.2.3
  diff -u -r1.2.2.2 -r1.2.2.3
  --- XMLResponseMethodBase.java        5 Feb 2004 15:51:22 -0000       1.2.2.2
  +++ XMLResponseMethodBase.java        9 Apr 2004 15:45:47 -0000       1.2.2.3
  @@ -251,9 +251,10 @@
        */
       public void parseResponse(InputStream input, HttpState state, HttpConnection 
conn)
           throws IOException, HttpException {
  -        // Also accept OK sent by buggy servers in reply to a PROPFIND.
  +        // Also accept OK sent by buggy servers in reply to a PROPFIND or
  +        // REPORT (Xythos, Catacomb, ...?).
           if (getStatusCode() == WebdavStatus.SC_MULTI_STATUS
  -            || this instanceof PropFindMethod
  +            || (this instanceof PropFindMethod || this instanceof ReportMethod)
                   && getStatusCode() == HttpStatus.SC_OK) {
               try {
                   parseXMLResponse(input);
  @@ -322,9 +323,11 @@
               responseURLs = new Vector();
               int status = getStatusLine().getStatusCode();
   
  -            // Also accept OK sent by buggy servers in reply to a PROPFIND.
  +            // Also accept OK sent by buggy servers in reply to a PROPFIND
  +            // or REPORT (Xythos, Catacomb, ...?).
               if (status == WebdavStatus.SC_MULTI_STATUS
  -                || this instanceof PropFindMethod
  +                || (this instanceof PropFindMethod
  +                    || this instanceof ReportMethod)
                       && status == HttpStatus.SC_OK) {
   
                   Element multistatus =
  
  
  

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

Reply via email to