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

[Bug] git svn reports an error when a temp file is too large

From
FFFlurin Feuerstein <flufeu@gmail.com>
Date
Oct 21, 2020, 18:33 UTC
Message-ID
<CADVShLvZ9Nwbix97g6OXGu6XwXxzbxNAa=VcpXqOzqTJoQp2+Q@mail.gmail.com>
git svn reports an error when a temp file is too large

The issue happens when (for an unknown reason) a temp file is generated that is too large. The exception is thrown in Git.pm on line 1344 in the function File::Temp::tempfile(). The method breaks when a string with more than about 260 characters is inserted. This is a limitation of the Perl File::Temp::tempfile() function itself (tested on both linux and windows computers).

I have managed to work around the issue by changing the way the method is invoked. I have forked the git repository on github and made a quick fix there: https://github.com/fxredeemer/git

Since I am completely inexperienced in Perl I am not sure whether this fix represents clean code.

There is also another workaround in that repository for a follow up issue (not part of this bug report).

Unfortunately I am unable to provide the repository since it is company internal and not open source.

Used version: 2.28 Used OS: Win 10 2004 (also happening on Ubuntu 18.04)

Regards Flurin

Message 1 of 1 in “[Bug] git svn reports an error when a temp file is too large”
  1. Flurin FeuersteinOct 21, 2020

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.