Re: [PATCH] Fix in Git.pm cat_blob crashes on large files (reviewed by Jeff King)

2013-02-22 Thread Erik Faye-Lund
On Fri, Feb 22, 2013 at 6:03 PM, Joshua Clayton wrote: > Read and write each 1024 byte buffer, rather than trying to buffer > the entire content of the file. > Previous code would crash on all files > 2 Gib, when the offset variable > became negative (perhaps below the level of perl), resulting in

[PATCH] Fix in Git.pm cat_blob crashes on large files (reviewed by Jeff King)

2013-02-22 Thread Joshua Clayton
Read and write each 1024 byte buffer, rather than trying to buffer the entire content of the file. Previous code would crash on all files > 2 Gib, when the offset variable became negative (perhaps below the level of perl), resulting in a crash. On a 32 bit system, or a system with low memory it mig