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:
authorVicent Martí <tanoku@gmail.com>2012-05-18 03:21:06 +0400
committerVicent Martí <tanoku@gmail.com>2012-05-18 03:26:26 +0400
commite172cf082e62aa421703080d0bccb7b8762c8bd4 (patch)
treec19f7b1be056a9176d4e865f5be5c69a5c2912c6 /src/refs.c
parent2e2e97858de18abd43f7e59fcc6151510c6d3272 (diff)
errors: Rename the generic return codes
Diffstat (limited to 'src/refs.c')
-rw-r--r--src/refs.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/refs.c b/src/refs.c
index 1ef3e13a4..88e2218d1 100644
--- a/src/refs.c
+++ b/src/refs.c
@@ -437,7 +437,7 @@ static int packed_load(git_repository *repo)
* for us here, so just return. Anything else means we need to
* refresh the packed refs.
*/
- if (result == GIT_ENOTFOUND) {
+ if (result == GIT_NOTFOUND) {
git_strmap_clear(ref_cache->packfile);
return 0;
}
@@ -917,7 +917,7 @@ static int reference_can_write(
if (exists) {
giterr_set(GITERR_REFERENCE,
"A reference with that name (%s) already exists", refname);
- return GIT_EEXISTS;
+ return GIT_EXISTS;
}
}
@@ -962,7 +962,7 @@ static int packed_lookup(git_reference *ref)
pos = git_strmap_lookup_index(packfile_refs, ref->name);
if (!git_strmap_valid_index(packfile_refs, pos)) {
giterr_set(GITERR_REFERENCE, "Reference '%s' not found", ref->name);
- return GIT_ENOTFOUND;
+ return GIT_NOTFOUND;
}
pack_ref = git_strmap_value_at(packfile_refs, pos);
@@ -984,7 +984,7 @@ static int reference_lookup(git_reference *ref)
/* only try to lookup this reference on the packfile if it
* wasn't found on the loose refs; not if there was a critical error */
- if (result == GIT_ENOTFOUND) {
+ if (result == GIT_NOTFOUND) {
giterr_clear();
result = packed_lookup(ref);
if (result == 0)