diff options
author | Ron Yorston <rmy@pobox.com> | 2016-10-24 08:54:44 +0100 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2016-10-24 08:54:44 +0100 |
commit | bbb2af5e5016f5d79e0b5d0c1312934b3ccd815d (patch) | |
tree | ab995441c0664dbc62fa412425a2a39bbcf97115 | |
parent | e135a80b90661689b9912d708b1a40344844192e (diff) | |
download | busybox-w32-bbb2af5e5016f5d79e0b5d0c1312934b3ccd815d.tar.gz busybox-w32-bbb2af5e5016f5d79e0b5d0c1312934b3ccd815d.tar.bz2 busybox-w32-bbb2af5e5016f5d79e0b5d0c1312934b3ccd815d.zip |
diff: use TMPDIR rather than TMP/TEMP
The getenv function in win32/env.c already handles replacing TMPDIR
with TMP/TEMP on Microsoft Windows.
-rw-r--r-- | editors/diff.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editors/diff.c b/editors/diff.c index 5c8a55b93..0ae7e20b3 100644 --- a/editors/diff.c +++ b/editors/diff.c | |||
@@ -747,7 +747,7 @@ static int diffreg(char *file[2]) | |||
747 | #else | 747 | #else |
748 | int fd_tmp; | 748 | int fd_tmp; |
749 | 749 | ||
750 | if (!(tmpdir=getenv("TMP")) && !(tmpdir=getenv("TEMP"))) | 750 | if (!(tmpdir=getenv("TMPDIR"))) |
751 | goto out; | 751 | goto out; |
752 | tmpfile[i] = xasprintf("%s/difXXXXXX", tmpdir); | 752 | tmpfile[i] = xasprintf("%s/difXXXXXX", tmpdir); |
753 | fd_tmp = xmkstemp(tmpfile[i]); | 753 | fd_tmp = xmkstemp(tmpfile[i]); |