diff options
author | Jonathan Tan <jonathantanmy@google.com> | 2018-06-14 15:54:28 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-06-15 08:44:24 -0700 |
commit | ec06283844a90c3e9440286401e9ad7d86daa5ae (patch) | |
tree | 57270c7f90133aa44cd9486248168321ab7527d6 /negotiator/default.h | |
parent | fetch-pack: move common check and marking together (diff) | |
download | tgif-ec06283844a90c3e9440286401e9ad7d86daa5ae.tar.xz |
fetch-pack: introduce negotiator API
Introduce the new files fetch-negotiator.{h,c}, which contains an API
behind which the details of negotiation are abstracted. Currently, only
one algorithm is available: the existing one.
This patch is written to be easily reviewed: static functions are
moved verbatim from fetch-pack.c to negotiator/default.c, and it can be
seen that the lines replaced by negotiator->X() calls are present in the
X() functions respectively.
Signed-off-by: Jonathan Tan <jonathantanmy@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'negotiator/default.h')
-rw-r--r-- | negotiator/default.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/negotiator/default.h b/negotiator/default.h new file mode 100644 index 0000000000..d23a8f2fb8 --- /dev/null +++ b/negotiator/default.h @@ -0,0 +1,8 @@ +#ifndef NEGOTIATOR_DEFAULT_H +#define NEGOTIATOR_DEFAULT_H + +struct fetch_negotiator; + +void default_negotiator_init(struct fetch_negotiator *negotiator); + +#endif |