Hi,
Find attached my fix that solves this problem:
Data uploaded from a client occasionally gets corrupted
by the isapi_redirector2 filter, if the length of the
data exceeds approximately 56k bytes.

A word of warning is appropriate here: The fix is in the
common part of jk2 but I have only tested on IIS, where
it does the job.

The fix is from v. 1.27 of jk/native2/common/jk_requtil.c

Please bear with me if I made some mistake using the diff
command--I'm neither from the Unix nor freeware world.

Regards,
Joakim Strom
--- jk/native2/common/jk_requtil.c.orig 2002-12-11 16:52:47.000000000 +0100
+++ jk/native2/common/jk_requtil.c      2002-12-11 17:04:30.000000000 +0100
@@ -434,7 +434,8 @@
                          unsigned  len)
 {
     unsigned rdlen = 0;
-    unsigned padded_len = len;
+    unsigned padded_len = len;
+       long content_read = s->content_read; /* save input value */
 
     if (s->is_chunked && s->no_more_chunks) {
        return 0;
@@ -453,8 +454,9 @@
         unsigned this_time = 0;
         if(s->read(env, s, buf + rdlen, len - rdlen, &this_time)) {
             return -1;
-        }
-
+        }
+               s->content_read += this_time; /* make sure content_read always gets 
+incremented */
+               
         if(0 == this_time) {
            if (s->is_chunked) {
                s->no_more_chunks = 1; /* read no more */
@@ -462,7 +464,8 @@
             break;
         }
         rdlen += this_time;
-    }
+    }
+       s->content_read = content_read; /* reset */
 
     return (int)rdlen;
 }

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

Reply via email to