git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [BUG] Out of memory in Git.pm

From
AMAlexander Miseler <alexander@miseler.de>
Date
Mar 3, 2011, 08:37 UTC
Message-ID
<loom.20110303T093108-235@post.gmane.org>
In-Reply-To
<4D6E3FB7.60600@tweerlei.de>
Robert Wruck <wruck <at> tweerlei.de> writes:
> there seems to be a problem in Git.pm (git-1.7.4.1, sub cat_blob, line 
> 891) where the whole object is read into memory ($blob) before writing 

There already seems to be a fix for this in git://repo.or.cz/git/mingw/4msysgit.git but I couldn't find the commit in git://git.kernel.org/pub/scm/git/git.git:

Author: Gregor Uhlenheuer (kongo2002@googlemail.com) Author date: 13 days ago (Fri Feb 18 11:42:12 2011 +0100) Committer: Johannes Schindelin (johannes.schindelin@gmx.de) Commit date: 13 days ago (Fri Feb 18 17:09:08 2011 +0100) Commit hash: e91fdbabfe29b6e37f1bc582316a82f7784a0275

Git.pm: Use stream-like writing in cat_blob()

This commit fixes the issue with the handling of large files causing an 'Out of memory' perl exception. Instead of reading and writing the whole blob at once now the blob is written in small pieces.

The problem was raised and discussed in this mail to the msysGit mailing list: http://thread.gmane.org/gmane.comp.version-control.msysgit/12080

Signed-off-by: Gregor Uhlenheuer <kongo2002@googlemail.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>

Contained in branches: devel Contained in no tag

Previous: Robert Wruck
Message 2 of 2 in “[BUG] Out of memory in Git.pm”
  1. Robert WruckMar 2, 2011
  2. Alexander MiselerMar 3, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.