summaryrefslogtreecommitdiff
path: root/builtin-pack-objects.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2009-03-21 22:53:36 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2009-03-21 22:53:36 -0700
commit2990034f1ed2c3d85d23d5611a1f04d317f785ac (patch)
treeb279df7a87a679a74c942f1c32d42681f9317f4b /builtin-pack-objects.c
parentMerge branch 'maint-1.6.0' into maint-1.6.1 (diff)
parentFix odb_mkstemp() on AIX (diff)
downloadtgif-2990034f1ed2c3d85d23d5611a1f04d317f785ac.tar.xz
Merge branch 'jc/maint-1.6.0-pack-directory' into maint-1.6.1
* jc/maint-1.6.0-pack-directory: Fix odb_mkstemp() on AIX Make sure objects/pack exists before creating a new pack Conflicts: wrapper.c
Diffstat (limited to 'builtin-pack-objects.c')
-rw-r--r--builtin-pack-objects.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/builtin-pack-objects.c b/builtin-pack-objects.c
index b616994f45..7079fab7db 100644
--- a/builtin-pack-objects.c
+++ b/builtin-pack-objects.c
@@ -488,9 +488,8 @@ static void write_pack_file(void)
} else {
char tmpname[PATH_MAX];
int fd;
- snprintf(tmpname, sizeof(tmpname),
- "%s/pack/tmp_pack_XXXXXX", get_object_directory());
- fd = xmkstemp(tmpname);
+ fd = odb_mkstemp(tmpname, sizeof(tmpname),
+ "pack/tmp_pack_XXXXXX");
pack_tmp_name = xstrdup(tmpname);
f = sha1fd(fd, pack_tmp_name);
}