diff options
| author | tb <> | 2022-01-14 08:21:12 +0000 |
|---|---|---|
| committer | tb <> | 2022-01-14 08:21:12 +0000 |
| commit | ac16e54e75a14731990afd6a000b7a0ea3cdbfc8 (patch) | |
| tree | d35ba256e6406a4df9d8d22f3053ae363531bf9f /src/lib/libcrypto/comp/comp.h | |
| parent | 0d97b61e5731530ddae73ec68940b695333cddb8 (diff) | |
| download | openbsd-ac16e54e75a14731990afd6a000b7a0ea3cdbfc8.tar.gz openbsd-ac16e54e75a14731990afd6a000b7a0ea3cdbfc8.tar.bz2 openbsd-ac16e54e75a14731990afd6a000b7a0ea3cdbfc8.zip | |
Make structs in comp.h opaque
This moves COMP_CTX and COMP_METHOD to comp_local.h and provides
missing typedefs in ossl_typ.h.
ok inoguchi jsing
Diffstat (limited to '')
| -rw-r--r-- | src/lib/libcrypto/comp/comp.h | 29 |
1 files changed, 1 insertions, 28 deletions
diff --git a/src/lib/libcrypto/comp/comp.h b/src/lib/libcrypto/comp/comp.h index fe7397f8ea..7c99ead358 100644 --- a/src/lib/libcrypto/comp/comp.h +++ b/src/lib/libcrypto/comp/comp.h | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: comp.h,v 1.8 2014/11/03 16:58:28 tedu Exp $ */ | 1 | /* $OpenBSD: comp.h,v 1.9 2022/01/14 08:21:12 tb Exp $ */ |
| 2 | 2 | ||
| 3 | #ifndef HEADER_COMP_H | 3 | #ifndef HEADER_COMP_H |
| 4 | #define HEADER_COMP_H | 4 | #define HEADER_COMP_H |
| @@ -9,33 +9,6 @@ | |||
| 9 | extern "C" { | 9 | extern "C" { |
| 10 | #endif | 10 | #endif |
| 11 | 11 | ||
| 12 | typedef struct comp_ctx_st COMP_CTX; | ||
| 13 | |||
| 14 | typedef struct comp_method_st { | ||
| 15 | int type; /* NID for compression library */ | ||
| 16 | const char *name; /* A text string to identify the library */ | ||
| 17 | int (*init)(COMP_CTX *ctx); | ||
| 18 | void (*finish)(COMP_CTX *ctx); | ||
| 19 | int (*compress)(COMP_CTX *ctx, unsigned char *out, unsigned int olen, | ||
| 20 | unsigned char *in, unsigned int ilen); | ||
| 21 | int (*expand)(COMP_CTX *ctx, unsigned char *out, unsigned int olen, | ||
| 22 | unsigned char *in, unsigned int ilen); | ||
| 23 | /* The following two do NOTHING, but are kept for backward compatibility */ | ||
| 24 | long (*ctrl)(void); | ||
| 25 | long (*callback_ctrl)(void); | ||
| 26 | } COMP_METHOD; | ||
| 27 | |||
| 28 | struct comp_ctx_st { | ||
| 29 | COMP_METHOD *meth; | ||
| 30 | unsigned long compress_in; | ||
| 31 | unsigned long compress_out; | ||
| 32 | unsigned long expand_in; | ||
| 33 | unsigned long expand_out; | ||
| 34 | |||
| 35 | CRYPTO_EX_DATA ex_data; | ||
| 36 | }; | ||
| 37 | |||
| 38 | |||
| 39 | COMP_CTX *COMP_CTX_new(COMP_METHOD *meth); | 12 | COMP_CTX *COMP_CTX_new(COMP_METHOD *meth); |
| 40 | void COMP_CTX_free(COMP_CTX *ctx); | 13 | void COMP_CTX_free(COMP_CTX *ctx); |
| 41 | int COMP_compress_block(COMP_CTX *ctx, unsigned char *out, int olen, | 14 | int COMP_compress_block(COMP_CTX *ctx, unsigned char *out, int olen, |
