From ded2c097bae67e00f8b4f3f777a516254207ca15 Mon Sep 17 00:00:00 2001 From: Xiaolong Ye Date: Tue, 26 Apr 2016 15:51:21 +0800 Subject: patch-ids: make commit_patch_id() a public helper function Make commit_patch_id() available to other builtins. Signed-off-by: Xiaolong Ye Signed-off-by: Junio C Hamano diff --git a/patch-ids.c b/patch-ids.c index b7b3e5a..a4d0016 100644 --- a/patch-ids.c +++ b/patch-ids.c @@ -4,7 +4,7 @@ #include "sha1-lookup.h" #include "patch-ids.h" -static int commit_patch_id(struct commit *commit, struct diff_options *options, +int commit_patch_id(struct commit *commit, struct diff_options *options, unsigned char *sha1) { if (commit->parents) diff --git a/patch-ids.h b/patch-ids.h index c8c7ca1..eeb56b3 100644 --- a/patch-ids.h +++ b/patch-ids.h @@ -13,6 +13,8 @@ struct patch_ids { struct patch_id_bucket *patches; }; +int commit_patch_id(struct commit *commit, struct diff_options *options, + unsigned char *sha1); int init_patch_ids(struct patch_ids *); int free_patch_ids(struct patch_ids *); struct patch_id *add_commit_patch_id(struct commit *, struct patch_ids *); -- cgit v0.10.2-6-g49f6