cmlenz      02/03/05 13:21:23

  Modified:    src/webdav/server/org/apache/slide/webdav/method Tag:
                        SLIDE_1_0 MkcolMethod.java
  Log:
  Ported to 1.0 branch:
  ---------------------
  Fix for compliance problem discovered by Tomislav Jukic (t0mislav at hotmail.com)
  using Litmus 0.5: Test basic-11. (mkcol_with_body)
  - Now returns status 415 (Unsupported Media Type) if request body is
    anything more than 0.
  [Please check conformance with our testsuite, as I haven't set that up
  correctly yet.]
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.14.2.2  +9 -3      
jakarta-slide/src/webdav/server/org/apache/slide/webdav/method/MkcolMethod.java
  
  Index: MkcolMethod.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-slide/src/webdav/server/org/apache/slide/webdav/method/MkcolMethod.java,v
  retrieving revision 1.14.2.1
  retrieving revision 1.14.2.2
  diff -u -r1.14.2.1 -r1.14.2.2
  --- MkcolMethod.java  2 Mar 2002 16:21:02 -0000       1.14.2.1
  +++ MkcolMethod.java  5 Mar 2002 21:21:23 -0000       1.14.2.2
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-slide/src/webdav/server/org/apache/slide/webdav/method/MkcolMethod.java,v
 1.14.2.1 2002/03/02 16:21:02 cmlenz Exp $
  - * $Revision: 1.14.2.1 $
  - * $Date: 2002/03/02 16:21:02 $
  + * $Header: 
/home/cvs/jakarta-slide/src/webdav/server/org/apache/slide/webdav/method/MkcolMethod.java,v
 1.14.2.2 2002/03/05 21:21:23 cmlenz Exp $
  + * $Revision: 1.14.2.2 $
  + * $Date: 2002/03/05 21:21:23 $
    *
    * ====================================================================
    *
  @@ -122,6 +122,12 @@
        */
       protected void parseRequest()
           throws WebdavException {
  +        
  +        if (req.getContentLength() > 0) {
  +            resp.setStatus(WebdavStatus.SC_UNSUPPORTED_MEDIA_TYPE);
  +            throw new WebdavException(WebdavStatus.SC_UNSUPPORTED_MEDIA_TYPE);
  +        }
  +        
           colName = requestUri;
           if (colName == null) {
               colName = "/";
  
  
  

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

Reply via email to