diff options
author | Ben Straub <bs@github.com> | 2012-12-14 13:46:45 -0800 |
---|---|---|
committer | Ben Straub <bs@github.com> | 2012-12-14 13:46:45 -0800 |
commit | b9e7e2b4e148deb90119d4c2c52d8d9e889527cd (patch) | |
tree | 731eff52328710a47cd702b63430c575e1bfb999 /src/clone.c | |
parent | 0015b5875eda08fe1e593942710125e9db7896b5 (diff) | |
download | libgit2-b9e7e2b4e148deb90119d4c2c52d8d9e889527cd.tar.gz |
Move non-options back out of options struct
Diffstat (limited to 'src/clone.c')
-rw-r--r-- | src/clone.c | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/src/clone.c b/src/clone.c index ab22d9ead..865521bce 100644 --- a/src/clone.c +++ b/src/clone.c @@ -355,16 +355,23 @@ static int clone_internal( return retcode; } -int git_clone(git_clone_options *options) +int git_clone( + git_repository **out, + git_remote *origin, + const char *local_path, + const git_clone_options *options) { - assert(options && options->out && options->origin_remote && options->local_path); + git_clone_options dummy_options = GIT_CLONE_OPTIONS_INIT; + + assert(out && origin && local_path); + if (!options) options = &dummy_options; GITERR_CHECK_VERSION(options, GIT_CLONE_OPTIONS_VERSION, "git_clone_options"); return clone_internal( - options->out, - options->origin_remote, - options->local_path, + out, + origin, + local_path, options->fetch_progress_cb, options->fetch_progress_payload, options->checkout_opts, |