summaryrefslogtreecommitdiff
path: root/src/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/util.c')
-rw-r--r--src/util.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/util.c b/src/util.c
index d2309124b..679917e36 100644
--- a/src/util.c
+++ b/src/util.c
@@ -38,11 +38,12 @@ int git__fnmatch(const char *pattern, const char *name, int flags)
ret = p_fnmatch(pattern, name, flags);
switch (ret) {
case 0:
- return GIT_SUCCESS;
+ return 0;
case FNM_NOMATCH:
return GIT_ENOMATCH;
default:
- return git__throw(GIT_EOSERR, "Error trying to match path");
+ giterr_set(GITERR_OS, "Error trying to match path");
+ return -1;
}
}