ozeigermann    2004/12/13 07:56:21

  Modified:    src/webdav/server/org/apache/slide/webdav/method
                        PutMethod.java
  Log:
  Repeation of conflicting transactions requires the content to be buffered.
  
  Revision  Changes    Path
  1.87      +9 -5      
jakarta-slide/src/webdav/server/org/apache/slide/webdav/method/PutMethod.java
  
  Index: PutMethod.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-slide/src/webdav/server/org/apache/slide/webdav/method/PutMethod.java,v
  retrieving revision 1.86
  retrieving revision 1.87
  diff -u -r1.86 -r1.87
  --- PutMethod.java    6 Dec 2004 08:54:13 -0000       1.86
  +++ PutMethod.java    13 Dec 2004 15:56:21 -0000      1.87
  @@ -237,7 +237,9 @@
                   
                   // Get content length
                   int contentLength = req.getContentLength();
  -                if (contentLength == (-1)) {
  +                // we need to buffer the content to find out the content 
length
  +                // and to save it for a retry
  +                if (contentLength == -1 || retryUponConflict) {
                        contentLength = 
revisionContent.getContentBytes().length;
                   }
                   revisionDescriptor.setContentLength(contentLength);
  @@ -408,7 +410,9 @@
                   
                   // Get content length
                   int contentLength = req.getContentLength();
  -                if (contentLength == -1) {
  +                // we need to buffer the content to find out the content 
length
  +                // and to save it for a retry
  +                if (contentLength == -1 || retryUponConflict) {
                       contentLength = revisionContent.getContentBytes().length;
                   }
                   revisionDescriptor.setContentLength(contentLength);
  
  
  

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

Reply via email to