aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--fast-import.c4
-rw-r--r--index-pack.c4
-rw-r--r--sha1_file.c4
3 files changed, 6 insertions, 6 deletions
diff --git a/fast-import.c b/fast-import.c
index 55ffae4fa..bea12151c 100644
--- a/fast-import.c
+++ b/fast-import.c
@@ -630,7 +630,7 @@ static void start_packfile(void)
int pack_fd;
snprintf(tmpfile, sizeof(tmpfile),
- "%s/pack_XXXXXX", get_object_directory());
+ "%s/tmp_pack_XXXXXX", get_object_directory());
pack_fd = mkstemp(tmpfile);
if (pack_fd < 0)
die("Can't create %s: %s", tmpfile, strerror(errno));
@@ -730,7 +730,7 @@ static char *create_index(void)
}
snprintf(tmpfile, sizeof(tmpfile),
- "%s/index_XXXXXX", get_object_directory());
+ "%s/tmp_idx_XXXXXX", get_object_directory());
idx_fd = mkstemp(tmpfile);
if (idx_fd < 0)
die("Can't create %s: %s", tmpfile, strerror(errno));
diff --git a/index-pack.c b/index-pack.c
index 61eb20e45..6284fe376 100644
--- a/index-pack.c
+++ b/index-pack.c
@@ -139,7 +139,7 @@ static const char *open_pack_file(const char *pack_name)
if (!pack_name) {
static char tmpfile[PATH_MAX];
snprintf(tmpfile, sizeof(tmpfile),
- "%s/pack_XXXXXX", get_object_directory());
+ "%s/tmp_pack_XXXXXX", get_object_directory());
output_fd = mkstemp(tmpfile);
pack_name = xstrdup(tmpfile);
} else
@@ -690,7 +690,7 @@ static const char *write_index_file(const char *index_name, unsigned char *sha1)
if (!index_name) {
static char tmpfile[PATH_MAX];
snprintf(tmpfile, sizeof(tmpfile),
- "%s/index_XXXXXX", get_object_directory());
+ "%s/tmp_idx_XXXXXX", get_object_directory());
fd = mkstemp(tmpfile);
index_name = xstrdup(tmpfile);
} else {
diff --git a/sha1_file.c b/sha1_file.c
index 940bab561..e412c70f2 100644
--- a/sha1_file.c
+++ b/sha1_file.c
@@ -1979,7 +1979,7 @@ int write_sha1_file(void *buf, unsigned long len, const char *type, unsigned cha
return error("sha1 file %s: %s\n", filename, strerror(errno));
}
- snprintf(tmpfile, sizeof(tmpfile), "%s/obj_XXXXXX", get_object_directory());
+ snprintf(tmpfile, sizeof(tmpfile), "%s/tmp_obj_XXXXXX", get_object_directory());
fd = mkstemp(tmpfile);
if (fd < 0) {
@@ -2105,7 +2105,7 @@ int write_sha1_from_fd(const unsigned char *sha1, int fd, char *buffer,
int ret;
SHA_CTX c;
- snprintf(tmpfile, sizeof(tmpfile), "%s/obj_XXXXXX", get_object_directory());
+ snprintf(tmpfile, sizeof(tmpfile), "%s/tmp_obj_XXXXXX", get_object_directory());
local = mkstemp(tmpfile);
if (local < 0) {