summaryrefslogtreecommitdiff
path: root/src/notes.c
diff options
context:
space:
mode:
authorVicent Martí <tanoku@gmail.com>2012-05-18 01:21:06 +0200
committerVicent Martí <tanoku@gmail.com>2012-05-18 01:26:26 +0200
commite172cf082e62aa421703080d0bccb7b8762c8bd4 (patch)
treec19f7b1be056a9176d4e865f5be5c69a5c2912c6 /src/notes.c
parent2e2e97858de18abd43f7e59fcc6151510c6d3272 (diff)
downloadlibgit2-e172cf082e62aa421703080d0bccb7b8762c8bd4.tar.gz
errors: Rename the generic return codes
Diffstat (limited to 'src/notes.c')
-rw-r--r--src/notes.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/notes.c b/src/notes.c
index 84ad94087..afd6fc23d 100644
--- a/src/notes.c
+++ b/src/notes.c
@@ -73,7 +73,7 @@ static int find_blob(git_oid *blob, git_tree *tree, const char *target)
return 0;
}
}
- return GIT_ENOTFOUND;
+ return GIT_NOTFOUND;
}
static int note_write(git_oid *out, git_repository *repo,
@@ -96,11 +96,11 @@ static int note_write(git_oid *out, git_repository *repo,
return error;
error = find_blob(&oid, tree, target + fanout);
- if (error != GIT_ENOTFOUND) {
+ if (error != GIT_NOTFOUND) {
git_tree_free(tree);
if (!error) {
giterr_set(GITERR_REPOSITORY, "Note for '%s' exists already", target);
- error = GIT_EEXISTS;
+ error = GIT_EXISTS;
}
return error;
}
@@ -275,7 +275,7 @@ static int note_get_default_ref(const char **out, git_repository *repo)
return -1;
ret = git_config_get_string(out, cfg, "core.notesRef");
- if (ret == GIT_ENOTFOUND) {
+ if (ret == GIT_NOTFOUND) {
*out = GIT_NOTES_DEFAULT_REF;
return 0;
}
@@ -352,7 +352,7 @@ int git_note_create(
return -1;
error = git_reference_lookup(&ref, repo, notes_ref);
- if (error < 0 && error != GIT_ENOTFOUND)
+ if (error < 0 && error != GIT_NOTFOUND)
return error;
if (!error) {