summaryrefslogtreecommitdiff
path: root/src/patch_parse.c
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@github.com>2016-04-24 16:14:25 -0400
committerEdward Thomson <ethomson@github.com>2016-05-26 13:01:08 -0500
commit94e488a056942f1bb1ebbe7c9f0c693937726609 (patch)
tree3643c91f491d8f06c38a8289f791225956da69c5 /src/patch_parse.c
parent17572f67ed9a3eb57b981d97468bd216d571bf10 (diff)
downloadlibgit2-94e488a056942f1bb1ebbe7c9f0c693937726609.tar.gz
patch: differentiate not found and invalid patches
Diffstat (limited to 'src/patch_parse.c')
-rw-r--r--src/patch_parse.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/patch_parse.c b/src/patch_parse.c
index 70acdbc22..991802cb4 100644
--- a/src/patch_parse.c
+++ b/src/patch_parse.c
@@ -671,7 +671,8 @@ static int parse_patch_header(
continue;
}
- error = parse_err("no header in patch file");
+ giterr_set(GITERR_PATCH, "no patch found");
+ error = GIT_ENOTFOUND;
done:
return error;