nixpkgs/pkgs/tools/text/gnupatch
Ivan Trubach 23eacd40cf gnupatch: fix segfault on cleanup
See https://savannah.gnu.org/bugs/?57717

Reproducer:

```console
$ patch -p1 <<'EOF'
diff --git a/file2.txt b/file2.txt
index e69de29..d20e9cd 100644
--- a/file2.txt
+++ b/file2.txt
@@ -1 +1 @@
-old content
+new content
EOF
```

```
(repeated lines omitted)
patch: **** Can't create file file2.txt.orig : Too many open files
patch: **** Can't create file file2.txt.orig : Too many open files
patch: **** Can't create file file2.txt.origSegmentation fault (core dumped)
```
2024-08-26 16:34:47 +03:00
..
Abort_when_cleaning_up_fails.patch
Allow_input_files_to_be_missing_for_ed-style_patches.patch
CVE-2018-6951.patch
CVE-2018-6952.patch
CVE-2018-1000156.patch
CVE-2019-13636.patch
CVE-2019-13638-and-CVE-2018-20969.patch
default.nix