diff options
author | Russell Belfer <rb@github.com> | 2014-04-30 11:16:31 -0700 |
---|---|---|
committer | Russell Belfer <rb@github.com> | 2014-04-30 11:16:31 -0700 |
commit | 8655a8985bcf2891390d464401b198d629edbfc3 (patch) | |
tree | 342130ee269448aa7b31c37f56df9d2b02f63abb /src/status.c | |
parent | a4f9e1f0d41a9c78b304d3c1b8ef5270c30b208f (diff) | |
download | libgit2-rb/diff-update-index-stat-cache.tar.gz |
Fix remaining init_options inconsistenciesrb/diff-update-index-stat-cache
There were a couple of "init_opts()" functions a few more cases
of structure initialization that I somehow missed.
Diffstat (limited to 'src/status.c')
-rw-r--r-- | src/status.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/status.c b/src/status.c index bcc2692d2..8d7612f72 100644 --- a/src/status.c +++ b/src/status.c @@ -528,11 +528,8 @@ int git_status_init_options(git_status_options *opts, unsigned int version) int git_status_list_get_perfdata( git_diff_perfdata *out, const git_status_list *status) { - if (!out || out->version != GIT_DIFF_PERFDATA_VERSION) { - giterr_set(GITERR_INVALID, "Invalid version %d for git_diff_perfdata", - out ? out->version : 0); - return -1; - } + assert(out); + GITERR_CHECK_VERSION(out, GIT_DIFF_PERFDATA_VERSION, "git_diff_perfdata"); out->stat_calls = 0; out->oid_calculations = 0; |