diff options
| author | Carlos Martín Nieto <cmn@dwim.me> | 2015-04-22 15:45:21 +0200 |
|---|---|---|
| committer | Carlos Martín Nieto <cmn@dwim.me> | 2015-05-13 09:46:36 +0200 |
| commit | 058b753ceb8f6b25b77e57106b3a87997bc6362a (patch) | |
| tree | 2ad699eda443d924a51d18aaa61c22e10f7eba31 /include/git2/sys | |
| parent | 6fb373a0e8eeff3c94853ff0ac55ca6b561c44a1 (diff) | |
| download | libgit2-058b753ceb8f6b25b77e57106b3a87997bc6362a.tar.gz | |
remote: move the transport ctor to the callbacks
Instead of having it set in a different place from every other callback,
put it the main structure. This removes some state from the remote and
makes it behave more like clone, where the constructors are passed via
the options.
Diffstat (limited to 'include/git2/sys')
| -rw-r--r-- | include/git2/sys/transport.h | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/include/git2/sys/transport.h b/include/git2/sys/transport.h index d6ca8ff05..867fbcbce 100644 --- a/include/git2/sys/transport.h +++ b/include/git2/sys/transport.h @@ -30,8 +30,6 @@ typedef enum { GIT_TRANSPORTFLAGS_NONE = 0, } git_transport_flags_t; -typedef struct git_transport git_transport; - struct git_transport { unsigned int version; /* Set progress and error callbacks */ @@ -142,9 +140,6 @@ GIT_EXTERN(int) git_transport_new(git_transport **out, git_remote *owner, const */ GIT_EXTERN(int) git_transport_ssh_with_paths(git_transport **out, git_remote *owner, void *payload); -/* Signature of a function which creates a transport */ -typedef int (*git_transport_cb)(git_transport **out, git_remote *owner, void *param); - /** * Add a custom transport definition, to be used in addition to the built-in * set of transports that come with libgit2. @@ -353,21 +348,6 @@ GIT_EXTERN(int) git_smart_subtransport_ssh( git_transport* owner, void *param); -/** - * Sets a custom transport factory for the remote. The caller can use this - * function to override the transport used for this remote when performing - * network operations. - * - * @param remote the remote to configure - * @param transport_cb the function to use to create a transport - * @param payload opaque parameter passed to transport_cb - * @return 0 or an error code - */ -GIT_EXTERN(int) git_remote_set_transport( - git_remote *remote, - git_transport_cb transport_cb, - void *payload); - /** @} */ GIT_END_DECL #endif |
