X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=commit.h;h=12d100b8b6fcd092f3a6886a75c720011ef1b7dc;hb=cec3e186f7b76cdced54286ef1da42b6978c4c8d;hp=a2d571b97410fa857b4c177325c4556dac50fe3f;hpb=b04f826bf6e1b55e5bffdef5aedc83c202569f60;p=git.git diff --git a/commit.h b/commit.h index a2d571b97..12d100b8b 100644 --- a/commit.h +++ b/commit.h @@ -142,6 +142,7 @@ struct commit_graft { int nr_parent; /* < 0 if shallow commit */ unsigned char parent[FLEX_ARRAY][20]; /* more */ }; +typedef int (*each_commit_graft_fn)(const struct commit_graft *, void *); struct commit_graft *read_graft_line(char *buf, int len); int register_commit_graft(struct commit_graft *, int); @@ -153,7 +154,7 @@ extern struct commit_list *get_octopus_merge_bases(struct commit_list *in); extern int register_shallow(const unsigned char *sha1); extern int unregister_shallow(const unsigned char *sha1); -extern int write_shallow_commits(struct strbuf *out, int use_pack_protocol); +extern int for_each_commit_graft(each_commit_graft_fn, void *); extern int is_repository_shallow(void); extern struct commit_list *get_shallow_commits(struct object_array *heads, int depth, int shallow_flag, int not_shallow_flag);