| 539 | } |
| 540 | |
| 541 | static void rename_tmp_packfile(struct repository *repo, |
| 542 | struct strbuf *name_prefix, const char *source, |
| 543 | const char *ext) |
| 544 | { |
| 545 | size_t name_prefix_len = name_prefix->len; |
| 546 | |
| 547 | strbuf_addstr(name_prefix, ext); |
| 548 | if (finalize_object_file(repo, source, name_prefix->buf)) |
| 549 | die("unable to rename temporary file to '%s'", |
| 550 | name_prefix->buf); |
| 551 | strbuf_setlen(name_prefix, name_prefix_len); |
| 552 | } |
| 553 | |
| 554 | void rename_tmp_packfile_idx(struct repository *repo, |
| 555 | struct strbuf *name_buffer, |
no test coverage detected