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

1 messages from 2020-10-21 to 2020-10-21. Participants: Flurin Feuerstein.
Thread: https://gitlist.dev/t/54480

## Flurin Feuerstein, 2020-10-21 18:33

Subject: [Bug] git svn reports an error when a temp file is too large
Message-ID: <CADVShLvZ9Nwbix97g6OXGu6XwXxzbxNAa=VcpXqOzqTJoQp2+Q@mail.gmail.com>
URL: https://gitlist.dev/e/CADVShLvZ9Nwbix97g6OXGu6XwXxzbxNAa%3DVcpXqOzqTJoQp2%2BQ%40mail.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

```
