Signed-off-by: Stefan Beller <sbel...@google.com>
---
 commit.c | 6 +++---
 commit.h | 3 +--
 2 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/commit.c b/commit.c
index b241cc7979..b74086d43d 100644
--- a/commit.c
+++ b/commit.c
@@ -277,13 +277,13 @@ const void *get_cached_commit_buffer(struct repository 
*r, const struct commit *
        return v->buffer;
 }
 
-const void *get_commit_buffer_the_repository(const struct commit *commit, 
unsigned long *sizep)
+const void *get_commit_buffer(struct repository *r, const struct commit 
*commit, unsigned long *sizep)
 {
-       const void *ret = get_cached_commit_buffer(the_repository, commit, 
sizep);
+       const void *ret = get_cached_commit_buffer(r, commit, sizep);
        if (!ret) {
                enum object_type type;
                unsigned long size;
-               ret = read_sha1_file(the_repository, commit->object.oid.hash,
+               ret = read_sha1_file(r, commit->object.oid.hash,
                                     &type, &size);
                if (!ret)
                        die("cannot read commit object %s",
diff --git a/commit.h b/commit.h
index 33f7779602..77e131d15b 100644
--- a/commit.h
+++ b/commit.h
@@ -88,8 +88,7 @@ const void *get_cached_commit_buffer(struct repository *r, 
const struct commit *
  * from disk. The resulting memory should not be modified, and must be given
  * to unuse_commit_buffer when the caller is done.
  */
-#define get_commit_buffer(r, c, s) get_commit_buffer_##r(c, s)
-const void *get_commit_buffer_the_repository(const struct commit *, unsigned 
long *size);
+const void *get_commit_buffer(struct repository *r, const struct commit *, 
unsigned long *size);
 
 /*
  * Tell the commit subsytem that we are done with a particular commit buffer.
-- 
2.15.1.433.g936d1b9894.dirty

Reply via email to