Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@microsoft.com>2013-04-20 03:19:53 +0400
committerEdward Thomson <ethomson@microsoft.com>2013-04-20 03:43:17 +0400
commit4e4eab52f7c5062ea21ea278a38e48700e753883 (patch)
tree4c8133d7595b355e3150b4525e25ad25103d10ff /src/refdb_fs.c
parent4a38143c93dc705bc40109e3f79d7fac722d44d7 (diff)
alloc doesn't take a refdb; git_refdb_free nicely in the tests
Diffstat (limited to 'src/refdb_fs.c')
-rw-r--r--src/refdb_fs.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/refdb_fs.c b/src/refdb_fs.c
index 784749fd3..56b2b6a99 100644
--- a/src/refdb_fs.c
+++ b/src/refdb_fs.c
@@ -42,7 +42,6 @@ typedef struct refdb_fs_backend {
git_repository *repo;
const char *path;
- git_refdb *refdb;
git_refcache refcache;
} refdb_fs_backend;
@@ -430,12 +429,12 @@ static int loose_lookup(
goto done;
}
- *out = git_reference__alloc_symbolic(backend->refdb, ref_name, target);
+ *out = git_reference__alloc_symbolic(ref_name, target);
} else {
if ((error = loose_parse_oid(&oid, &ref_file)) < 0)
goto done;
- *out = git_reference__alloc(backend->refdb, ref_name, &oid, NULL);
+ *out = git_reference__alloc(ref_name, &oid, NULL);
}
if (*out == NULL)
@@ -484,7 +483,7 @@ static int packed_lookup(
if ((error = packed_map_entry(&entry, &pos, backend, ref_name)) < 0)
return error;
- if ((*out = git_reference__alloc(backend->refdb, ref_name,
+ if ((*out = git_reference__alloc(ref_name,
&entry->oid, &entry->peel)) == NULL)
return -1;
@@ -999,8 +998,7 @@ static void refdb_fs_backend__free(git_refdb_backend *_backend)
int git_refdb_backend_fs(
git_refdb_backend **backend_out,
- git_repository *repository,
- git_refdb *refdb)
+ git_repository *repository)
{
refdb_fs_backend *backend;
@@ -1009,7 +1007,6 @@ int git_refdb_backend_fs(
backend->repo = repository;
backend->path = repository->path_repository;
- backend->refdb = refdb;
backend->parent.exists = &refdb_fs_backend__exists;
backend->parent.lookup = &refdb_fs_backend__lookup;