patch to HTTP/Request.php for proper chunked content handling
| From: | David Sklar | Date: | Fri, 08 Mar 2002 18:22:45 +0000 |
| Subject: | patch to HTTP/Request.php for proper chunked content handling | ||
| Groups: | php.pear.dev | ||
| Request: | Send a blank email to pear-dev+get-4942@lists.php.net to get a copy of this message | ||
HTTP/Request.php does not stitch together received pieces of chunked content
properly. Instead of moving from chunk to chunk in the response body, it was
taking repeated substrings from the beginning of the body. Attached is a
patch that fixes this. It also removes the call to the pdd() debugging
function, which someone brought up in a previous message.
Because it uses substr() and strlen(), I'm not sure if this patch (or the
original code in HTTP/Request.php) is binary-safe (i.e. if there are ASCII 0
characters in the response body.) Does anyone have any thoughts about that?
Thanks,
-dave