On May 6, 2007, at 12:52 PM, Bernhard Graf wrote:
On Sunday 06 May 2007 16:58, Andy Grundman wrote:
I've checked in a simpler patch that just checks that $stat->size > 0
before setting the Content-Length.
I must admit that I am not sure if stat size of a pipe is always 0
- at
least I wouldn't rely on it. And of course a regular empty file has 0
bytes too.
On the other hand I don't know how portable this Fcntl stuff is.
That's why I opted for the easier solution, if $stat->size > 0 it's
should be safe to set Content-Length to that value.
_______________________________________________
List: [email protected]
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/[email protected]/
Dev site: http://dev.catalyst.perl.org/