]> asedeno.scripts.mit.edu Git - git.git/blobdiff - pack-write.c
return the prune-packed progress display to the inner loop
[git.git] / pack-write.c
index 1cf5f7c9f0956a457de03c64238d298a9d996984..d1ed3abe21502464ca0ec6b90c1b3272e3db6176 100644 (file)
@@ -17,7 +17,8 @@ static int sha1_compare(const void *_a, const void *_b)
  * the SHA1 hash of sorted object names. The objects array passed in
  * will be sorted by SHA1 on exit.
  */
-const char *write_idx_file(const char *index_name, struct pack_idx_entry **objects, int nr_objects, unsigned char *sha1)
+char *write_idx_file(char *index_name, struct pack_idx_entry **objects,
+                    int nr_objects, unsigned char *sha1)
 {
        struct sha1file *f;
        struct pack_idx_entry **sorted_by_sha, **list, **last;
@@ -45,7 +46,7 @@ const char *write_idx_file(const char *index_name, struct pack_idx_entry **objec
                static char tmpfile[PATH_MAX];
                snprintf(tmpfile, sizeof(tmpfile),
                         "%s/tmp_idx_XXXXXX", get_object_directory());
-               fd = mkstemp(tmpfile);
+               fd = xmkstemp(tmpfile);
                index_name = xstrdup(tmpfile);
        } else {
                unlink(index_name);