diff options
| author | Carlos Martín Nieto <cmn@dwim.me> | 2015-07-10 18:36:53 +0200 |
|---|---|---|
| committer | Carlos Martín Nieto <cmn@dwim.me> | 2015-07-10 18:36:53 +0200 |
| commit | f2a328fa2af103a2b6e4939dcd9cc3b3c3b7a0ac (patch) | |
| tree | aa4c8bc19a32ca7ef95f6ba6ada90bf9e33e1791 /include/git2 | |
| parent | 9847d80ddc97b85ca38e158dc4781f0a3c6081ca (diff) | |
| parent | 79698030b090b017aea6d33fb3f02d3fcb046738 (diff) | |
| download | libgit2-f2a328fa2af103a2b6e4939dcd9cc3b3c3b7a0ac.tar.gz | |
Merge pull request #3272 from ethomson/cert
git_cert: child types use proper base type
Diffstat (limited to 'include/git2')
| -rw-r--r-- | include/git2/transport.h | 35 |
1 files changed, 14 insertions, 21 deletions
diff --git a/include/git2/transport.h b/include/git2/transport.h index 2eeebd565..fd55eac0a 100644 --- a/include/git2/transport.h +++ b/include/git2/transport.h @@ -37,39 +37,32 @@ typedef enum { * Hostkey information taken from libssh2 */ typedef struct { + git_cert parent; + /** - * Type of certificate. Here to share the header with - * `git_cert`. + * A hostkey type from libssh2, either + * `GIT_CERT_SSH_MD5` or `GIT_CERT_SSH_SHA1` */ - git_cert_t cert_type; - /** - * A hostkey type from libssh2, either - * `GIT_CERT_SSH_MD5` or `GIT_CERT_SSH_SHA1` - */ git_cert_ssh_t type; - /** - * Hostkey hash. If type has `GIT_CERT_SSH_MD5` set, this will - * have the MD5 hash of the hostkey. - */ + /** + * Hostkey hash. If type has `GIT_CERT_SSH_MD5` set, this will + * have the MD5 hash of the hostkey. + */ unsigned char hash_md5[16]; - /** - * Hostkey hash. If type has `GIT_CERT_SSH_SHA1` set, this will - * have the SHA-1 hash of the hostkey. - */ - unsigned char hash_sha1[20]; + /** + * Hostkey hash. If type has `GIT_CERT_SSH_SHA1` set, this will + * have the SHA-1 hash of the hostkey. + */ + unsigned char hash_sha1[20]; } git_cert_hostkey; /** * X.509 certificate information */ typedef struct { - /** - * Type of certificate. Here to share the header with - * `git_cert`. - */ - git_cert_t cert_type; + git_cert parent; /** * Pointer to the X.509 certificate data */ |
