]> gitweb.ps.run Git - ps-cgit/commitdiff
shared: make cgit_diff_tree_cb public
authorJohn Keeping <john@keeping.me.uk>
Wed, 12 Aug 2015 14:34:48 +0000 (15:34 +0100)
committerJason A. Donenfeld <Jason@zx2c4.com>
Wed, 12 Aug 2015 14:57:30 +0000 (16:57 +0200)
This will allow us to use this nice wrapper function elsewhere, avoiding
dealing with the diff queue when we only need to inspect a filepair.

Signed-off-by: John Keeping <john@keeping.me.uk>
cgit.h
shared.c

diff --git a/cgit.h b/cgit.h
index db9a8ebefa76d820a94668334da5936b439fea77..b2253d22b078a3377f1879880819b60658a7172b 100644 (file)
--- a/cgit.h
+++ b/cgit.h
@@ -340,6 +340,9 @@ extern int cgit_refs_cb(const char *refname, const struct object_id *oid,
 
 extern void *cgit_free_commitinfo(struct commitinfo *info);
 
+void cgit_diff_tree_cb(struct diff_queue_struct *q,
+                      struct diff_options *options, void *data);
+
 extern int cgit_diff_files(const unsigned char *old_sha1,
                           const unsigned char *new_sha1,
                           unsigned long *old_size, unsigned long *new_size,
index a83afcb3e275bed29d41ec779bf019ddde7589c5..0431b59baf519442e80fbbed13df4ea3bdb56097 100644 (file)
--- a/shared.c
+++ b/shared.c
@@ -250,8 +250,8 @@ int cgit_refs_cb(const char *refname, const struct object_id *oid, int flags,
        return 0;
 }
 
-static void cgit_diff_tree_cb(struct diff_queue_struct *q,
-                             struct diff_options *options, void *data)
+void cgit_diff_tree_cb(struct diff_queue_struct *q,
+                      struct diff_options *options, void *data)
 {
        int i;