summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Straub <bs@github.com>2013-12-11 06:43:17 -0800
committerBen Straub <bs@github.com>2013-12-11 06:43:17 -0800
commit5a52d6be4c3a2635a3121b529e0ab2ab674f6be6 (patch)
tree9d2825c11d953ac3ca97a97c60f7b94e655ad622
parenta7c83aec2149a4885bfac032859142e8a62bceab (diff)
downloadlibgit2-5a52d6be4c3a2635a3121b529e0ab2ab674f6be6.tar.gz
Check version earlier
-rw-r--r--src/diff_tform.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/diff_tform.c b/src/diff_tform.c
index 3ff6108c8..702e43bd3 100644
--- a/src/diff_tform.c
+++ b/src/diff_tform.c
@@ -275,6 +275,8 @@ static int normalize_find_opts(
{
git_config *cfg = NULL;
+ GITERR_CHECK_VERSION(given, GIT_DIFF_FIND_OPTIONS_VERSION, "git_diff_find_options");
+
if (diff->repo != NULL &&
git_repository_config__weakptr(&cfg, diff->repo) < 0)
return -1;
@@ -302,7 +304,6 @@ static int normalize_find_opts(
opts->flags |= GIT_DIFF_FIND_RENAMES;
}
}
- GITERR_CHECK_VERSION(given, GIT_DIFF_FIND_OPTIONS_VERSION, "git_diff_find_options");
/* some flags imply others */