summaryrefslogtreecommitdiff
path: root/src/odb_pack.c
diff options
context:
space:
mode:
authorVicent Marti <tanoku@gmail.com>2011-06-16 02:48:48 +0200
committerVicent Marti <tanoku@gmail.com>2011-06-16 02:50:08 +0200
commitf1d018513aced2fb4e6c87f2d417b6f826dbe998 (patch)
treeed3f93db76dc70f854f20f4b3bd7f627c0ca6d19 /src/odb_pack.c
parentfa48608ec30758dbf6d0d26d3c4f8efba8efe8e9 (diff)
downloadlibgit2-f1d018513aced2fb4e6c87f2d417b6f826dbe998.tar.gz
oid: Uniformize ncmp methods
Drop redundant methods. The ncmp method is now public
Diffstat (limited to 'src/odb_pack.c')
-rw-r--r--src/odb_pack.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/odb_pack.c b/src/odb_pack.c
index d02338d62..8a88a0baa 100644
--- a/src/odb_pack.c
+++ b/src/odb_pack.c
@@ -26,10 +26,10 @@
#include "common.h"
#include "git2/zlib.h"
#include "git2/repository.h"
+#include "git2/oid.h"
#include "fileops.h"
#include "hash.h"
#include "odb.h"
-#include "oid.h"
#include "delta-apply.h"
#include "sha1_lookup.h"
@@ -1011,7 +1011,7 @@ static int pack_entry_find_offset(
if (pos < (int)p->num_objects) {
current = index + pos * stride;
- if (!git_oid_ncmp_raw(len, short_oid->id, current)) {
+ if (!git_oid_ncmp(short_oid, (const git_oid *)current, len)) {
found = 1;
}
}
@@ -1021,7 +1021,7 @@ static int pack_entry_find_offset(
/* Check for ambiguousity */
const unsigned char *next = current + stride;
- if (!git_oid_ncmp_raw(len, short_oid->id, next)) {
+ if (!git_oid_ncmp(short_oid, (const git_oid *)next, len)) {
found = 2;
}
}