termux-packages/packages/nano/src-files.c.patch

13 lines
443 B
Diff

diff -u -r ../nano-4.6/src/files.c ./src/files.c
--- ../nano-4.6/src/files.c 2019-11-29 10:12:07.000000000 +0000
+++ ./src/files.c 2019-12-01 16:31:03.622452000 +0000
@@ -1359,7 +1359,7 @@
tempdir = check_writable_directory(P_tmpdir);
if (tempdir == NULL)
- tempdir = copy_of("/tmp/");
+ tempdir = copy_of("@TERMUX_PREFIX@/tmp/");
tempfile_name = charealloc(tempdir, strlen(tempdir) + 12);
strcat(tempfile_name, "nano.XXXXXX");