if_iwm - Recognize IWM_FW_PAGING_BLOCK_CMD wide cmd response correctly.
[dragonfly.git] / crypto / openssl / crypto / comp / comp.h
blob60a073404e922f8b7448d115fdb5489feaae500f
2 #ifndef HEADER_COMP_H
3 # define HEADER_COMP_H
5 # include <openssl/crypto.h>
7 # ifdef OPENSSL_NO_COMP
8 # error COMP is disabled.
9 # endif
11 #ifdef __cplusplus
12 extern "C" {
13 #endif
15 typedef struct comp_ctx_st COMP_CTX;
17 typedef struct comp_method_st {
18 int type; /* NID for compression library */
19 const char *name; /* A text string to identify the library */
20 int (*init) (COMP_CTX *ctx);
21 void (*finish) (COMP_CTX *ctx);
22 int (*compress) (COMP_CTX *ctx,
23 unsigned char *out, unsigned int olen,
24 unsigned char *in, unsigned int ilen);
25 int (*expand) (COMP_CTX *ctx,
26 unsigned char *out, unsigned int olen,
27 unsigned char *in, unsigned int ilen);
29 * The following two do NOTHING, but are kept for backward compatibility
31 long (*ctrl) (void);
32 long (*callback_ctrl) (void);
33 } COMP_METHOD;
35 struct comp_ctx_st {
36 COMP_METHOD *meth;
37 unsigned long compress_in;
38 unsigned long compress_out;
39 unsigned long expand_in;
40 unsigned long expand_out;
41 CRYPTO_EX_DATA ex_data;
44 COMP_CTX *COMP_CTX_new(COMP_METHOD *meth);
45 void COMP_CTX_free(COMP_CTX *ctx);
46 int COMP_compress_block(COMP_CTX *ctx, unsigned char *out, int olen,
47 unsigned char *in, int ilen);
48 int COMP_expand_block(COMP_CTX *ctx, unsigned char *out, int olen,
49 unsigned char *in, int ilen);
50 COMP_METHOD *COMP_rle(void);
51 COMP_METHOD *COMP_zlib(void);
52 void COMP_zlib_cleanup(void);
54 # ifdef HEADER_BIO_H
55 # ifdef ZLIB
56 BIO_METHOD *BIO_f_zlib(void);
57 # endif
58 # endif
60 /* BEGIN ERROR CODES */
62 * The following lines are auto generated by the script mkerr.pl. Any changes
63 * made after this point may be overwritten when the script is next run.
65 void ERR_load_COMP_strings(void);
67 /* Error codes for the COMP functions. */
69 /* Function codes. */
70 # define COMP_F_BIO_ZLIB_FLUSH 99
71 # define COMP_F_BIO_ZLIB_NEW 100
72 # define COMP_F_BIO_ZLIB_READ 101
73 # define COMP_F_BIO_ZLIB_WRITE 102
75 /* Reason codes. */
76 # define COMP_R_ZLIB_DEFLATE_ERROR 99
77 # define COMP_R_ZLIB_INFLATE_ERROR 100
78 # define COMP_R_ZLIB_NOT_SUPPORTED 101
80 #ifdef __cplusplus
82 #endif
83 #endif