OSDN Git Service
(root)
/
android-x86
/
external-busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
689bbab
)
Change tmpfile path for diff to /data/local/tmp
author
Dylan Simon
<dylan@dylex.net>
Sun, 7 Feb 2010 22:34:41 +0000
(17:34 -0500)
committer
Dylan Simon
<dylan@dylex.net>
Sun, 7 Feb 2010 22:34:41 +0000
(17:34 -0500)
editors/diff.c
patch
|
blob
|
history
diff --git
a/editors/diff.c
b/editors/diff.c
index
5b7b51f
..
dc478e6
100644
(file)
--- a/
editors/diff.c
+++ b/
editors/diff.c
@@
-672,7
+672,12
@@
static int diffreg(char *file[2])
* When we meet non-seekable file, we must make a temp copy.
*/
if (lseek(fd, 0, SEEK_SET) == -1 && errno == ESPIPE) {
- char name[] = "/tmp/difXXXXXX";
+ /* really should use $TMPDIR, but not usually set on android anyway */
+ char name[] =
+#ifdef __BIONIC__
+ "/data/local"
+#endif
+ "/tmp/difXXXXXX";
int fd_tmp = mkstemp(name);
if (fd_tmp < 0)
bb_perror_msg_and_die("mkstemp");