|
From: <php...@li...> - 2010-02-07 16:48:36
|
On Sun, 2010-02-07 at 15:19 +0700, php...@li... wrote: > I'm just trying to download the response in a way How else do you want to download the files efficiently, if not via Transfer-Encoding: Chunked? > The downloads only fail 'sometimes', so I don't understand how some of > the explanations Given your code, the possibility that PHP reads "over the edge" depends on the file size. If the file is large it is more likely that this will happen. In any case, this isn't due to bugs in PHP or the PHP/Java Bridge, but due to your misunderstanding of how HTTP chunked encoding works and what fgets() and feof() do. Regards, Jost Bökemeier |