Since nginx 1.3.9, the request body handler is able to decode chunked encoding. This feature changed the behavior of the request body handler, whereas before the request_body->rest was decremented on each call to recv and the upload progress module was showing the correct rest decrement. Now, request_body->rest is only decremented when the incoming body buffer is reused. If this buffer is large (it's size depends on client_body_buffer_size), then it can never be reused, thus the rest field is never decremented until the end of the file. This hasn't been detected and reproduced before, because I happen to run the tests with small client_body_buffer_size (ie less than 10% from the file uploaded). The solution is to never use rest, but compute the correct rest by tracking the current buffer size. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>tags/v0.9.1
|
|
||
| 462 |
|
462 |
|
| 463 |
|
463 |
|
| 464 |
|
464 |
|
|
465 |
|
|
|
466 |
|
|
|
467 |
|
|
| 465 |
|
468 |
|
| 466 |
|
469 |
|
| 467 |
|
470 |
|
|
|
||
| 517 |
|
520 |
|
| 518 |
|
521 |
|
| 519 |
|
522 |
|
| 520 |
|
|
|
|
523 |
|
|
|
524 |
|
|
|
525 |
|
|
|
526 |
|
|
|
527 |
|
|
|
528 |
|
|
|
529 |
|
|
|
530 |
|
|
|
531 |
|
|
| 521 |
|
532 |
|
| 522 |
|
533 |
|
| 523 |
|
534 |
|