diff options
author | Edward Thomson <ethomson@edwardthomson.com> | 2019-02-21 10:38:53 +0000 |
---|---|---|
committer | Edward Thomson <ethomson@edwardthomson.com> | 2019-02-22 11:25:14 +0000 |
commit | 7506d34c0ca009a203aa649876707fed9ce3c901 (patch) | |
tree | 28e11e8f107cc485ade7e4c24f192db5e4a02b27 | |
parent | a1ef995dc03379fb1f5151b5d98d16644218c95e (diff) | |
download | libgit2-7506d34c0ca009a203aa649876707fed9ce3c901.tar.gz |
indexer: deprecate git_transfer_progress
Safely deprecate `git_transfer_progress` and `git_transfer_progress_cb`
types, forwarding them to the new `git_indexer_progress` and
`git_indexer_progress_cb`.
-rw-r--r-- | include/git2/deprecated.h | 29 | ||||
-rw-r--r-- | include/git2/indexer.h | 4 |
2 files changed, 29 insertions, 4 deletions
diff --git a/include/git2/deprecated.h b/include/git2/deprecated.h index 9d3a091a3..3777c0e00 100644 --- a/include/git2/deprecated.h +++ b/include/git2/deprecated.h @@ -245,6 +245,35 @@ GIT_EXTERN(void) giterr_set_oom(void); /**@}*/ +/** @name Deprecated Transfer Progress Types + * + * These types are retained for backward compatibility. The newer + * versions of these values should be preferred in all new code. + * + * There is no plan to remove these backward compatibility values at + * this time. + */ +/**@{*/ + +/** + * This structure is used to provide callers information about the + * progress of indexing a packfile. + * + * This type is deprecated, but there is no plan to remove this + * type definition at this time. + */ +typedef git_indexer_progress git_transfer_progress; + +/** + * Type definition for progress callbacks during indexing. + * + * This type is deprecated, but there is no plan to remove this + * type definition at this time. + */ +typedef git_indexer_progress_cb git_transfer_progress_cb; + +/**@}*/ + /** @} */ GIT_END_DECL diff --git a/include/git2/indexer.h b/include/git2/indexer.h index 094a12b1f..47c0289fa 100644 --- a/include/git2/indexer.h +++ b/include/git2/indexer.h @@ -46,8 +46,6 @@ typedef struct git_indexer_progress { size_t received_bytes; } git_indexer_progress; -typedef git_indexer_progress git_transfer_progress; - /** * Type for progress callbacks during indexing. Return a value less * than zero to cancel the indexing or download. @@ -57,8 +55,6 @@ typedef git_indexer_progress git_transfer_progress; */ typedef int GIT_CALLBACK(git_indexer_progress_cb)(const git_indexer_progress *stats, void *payload); -typedef git_indexer_progress_cb git_transfer_progress_cb; - typedef struct git_indexer_options { unsigned int version; |