diff options
| author | Russell Belfer <rb@github.com> | 2014-04-30 11:16:31 -0700 |
|---|---|---|
| committer | Russell Belfer <rb@github.com> | 2014-05-02 09:21:33 -0700 |
| commit | bc91347b5894c98964a12c6637d5ca91d9723b42 (patch) | |
| tree | 3b6ccd7b2d67336cc5aa4d4eaadd334552590e18 /src/status.c | |
| parent | 702efc891f2a620f10998062ba0c00b34100f632 (diff) | |
| download | libgit2-bc91347b5894c98964a12c6637d5ca91d9723b42.tar.gz | |
Fix remaining init_options inconsistencies
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; |
