diff options
Diffstat (limited to 'crypto/evp')
-rw-r--r-- | crypto/evp/bio_b64.c | 14 | ||||
-rw-r--r-- | crypto/evp/bio_enc.c | 16 | ||||
-rw-r--r-- | crypto/evp/bio_md.c | 14 | ||||
-rw-r--r-- | crypto/evp/bio_ok.c | 12 | ||||
-rw-r--r-- | crypto/evp/evp_pbe.c | 2 | ||||
-rw-r--r-- | crypto/evp/evp_pkey.c | 12 |
6 files changed, 35 insertions, 35 deletions
diff --git a/crypto/evp/bio_b64.c b/crypto/evp/bio_b64.c index bd5e24f993..e76387eaec 100644 --- a/crypto/evp/bio_b64.c +++ b/crypto/evp/bio_b64.c @@ -62,11 +62,11 @@ #include <openssl/buffer.h> #include <openssl/evp.h> -static int b64_write(BIO *h,char *buf,int num); -static int b64_read(BIO *h,char *buf,int size); -/*static int b64_puts(BIO *h,char *str); */ -/*static int b64_gets(BIO *h,char *str,int size); */ -static long b64_ctrl(BIO *h,int cmd,long arg1,char *arg2); +static int b64_write(BIO *h, const char *buf, int num); +static int b64_read(BIO *h, char *buf, int size); +/*static int b64_puts(BIO *h, const char *str); */ +/*static int b64_gets(BIO *h, char *str, int size); */ +static long b64_ctrl(BIO *h, int cmd, long arg1, void *arg2); static int b64_new(BIO *h); static int b64_free(BIO *data); static long b64_callback_ctrl(BIO *h,int cmd,void (*fp)()); @@ -340,7 +340,7 @@ static int b64_read(BIO *b, char *out, int outl) return((ret == 0)?ret_code:ret); } -static int b64_write(BIO *b, char *in, int inl) +static int b64_write(BIO *b, const char *in, int inl) { int ret=inl,n,i; BIO_B64_CTX *ctx; @@ -434,7 +434,7 @@ static int b64_write(BIO *b, char *in, int inl) return(ret); } -static long b64_ctrl(BIO *b, int cmd, long num, char *ptr) +static long b64_ctrl(BIO *b, int cmd, long num, void *ptr) { BIO_B64_CTX *ctx; long ret=1; diff --git a/crypto/evp/bio_enc.c b/crypto/evp/bio_enc.c index 629bf4b95d..1b7a21010c 100644 --- a/crypto/evp/bio_enc.c +++ b/crypto/evp/bio_enc.c @@ -62,14 +62,14 @@ #include <openssl/buffer.h> #include <openssl/evp.h> -static int enc_write(BIO *h,char *buf,int num); -static int enc_read(BIO *h,char *buf,int size); -/*static int enc_puts(BIO *h,char *str); */ -/*static int enc_gets(BIO *h,char *str,int size); */ -static long enc_ctrl(BIO *h,int cmd,long arg1,char *arg2); +static int enc_write(BIO *h, const char *buf, int num); +static int enc_read(BIO *h, char *buf, int size); +/*static int enc_puts(BIO *h, const char *str); */ +/*static int enc_gets(BIO *h, char *str, int size); */ +static long enc_ctrl(BIO *h, int cmd, long arg1, void *arg2); static int enc_new(BIO *h); static int enc_free(BIO *data); -static long enc_callback_ctrl(BIO *h,int cmd,void (*fp)()); +static long enc_callback_ctrl(BIO *h, int cmd, void (*fp)()); #define ENC_BLOCK_SIZE (1024*4) typedef struct enc_struct @@ -224,7 +224,7 @@ static int enc_read(BIO *b, char *out, int outl) return((ret == 0)?ctx->cont:ret); } -static int enc_write(BIO *b, char *in, int inl) +static int enc_write(BIO *b, const char *in, int inl) { int ret=0,n,i; BIO_ENC_CTX *ctx; @@ -279,7 +279,7 @@ static int enc_write(BIO *b, char *in, int inl) return(ret); } -static long enc_ctrl(BIO *b, int cmd, long num, char *ptr) +static long enc_ctrl(BIO *b, int cmd, long num, void *ptr) { BIO *dbio; BIO_ENC_CTX *ctx,*dctx; diff --git a/crypto/evp/bio_md.c b/crypto/evp/bio_md.c index aef928dd8f..f21319c04e 100644 --- a/crypto/evp/bio_md.c +++ b/crypto/evp/bio_md.c @@ -65,11 +65,11 @@ /* BIO_put and BIO_get both add to the digest, * BIO_gets returns the digest */ -static int md_write(BIO *h,char *buf,int num); -static int md_read(BIO *h,char *buf,int size); -/*static int md_puts(BIO *h,char *str); */ -static int md_gets(BIO *h,char *str,int size); -static long md_ctrl(BIO *h,int cmd,long arg1,char *arg2); +static int md_write(BIO *h, char const *buf, int num); +static int md_read(BIO *h, char *buf, int size); +/*static int md_puts(BIO *h, const char *str); */ +static int md_gets(BIO *h, char *str, int size); +static long md_ctrl(BIO *h, int cmd, long arg1, void *arg2); static int md_new(BIO *h); static int md_free(BIO *data); static long md_callback_ctrl(BIO *h,int cmd,void (*fp)()); @@ -139,7 +139,7 @@ static int md_read(BIO *b, char *out, int outl) return(ret); } -static int md_write(BIO *b, char *in, int inl) +static int md_write(BIO *b, const char *in, int inl) { int ret=0; EVP_MD_CTX *ctx; @@ -162,7 +162,7 @@ static int md_write(BIO *b, char *in, int inl) return(ret); } -static long md_ctrl(BIO *b, int cmd, long num, char *ptr) +static long md_ctrl(BIO *b, int cmd, long num, void *ptr) { EVP_MD_CTX *ctx,*dctx,**pctx; const EVP_MD **ppmd; diff --git a/crypto/evp/bio_ok.c b/crypto/evp/bio_ok.c index e6ff5f2cdb..4f9b703a36 100644 --- a/crypto/evp/bio_ok.c +++ b/crypto/evp/bio_ok.c @@ -125,12 +125,12 @@ #include <openssl/evp.h> #include <openssl/rand.h> -static int ok_write(BIO *h,char *buf,int num); -static int ok_read(BIO *h,char *buf,int size); -static long ok_ctrl(BIO *h,int cmd,long arg1,char *arg2); +static int ok_write(BIO *h, const char *buf, int num); +static int ok_read(BIO *h, char *buf, int size); +static long ok_ctrl(BIO *h, int cmd, long arg1, void *arg2); static int ok_new(BIO *h); static int ok_free(BIO *data); -static long ok_callback_ctrl(BIO *h,int cmd,void (*fp)()); +static long ok_callback_ctrl(BIO *h, int cmd, void (*fp)()); static void sig_out(BIO* b); static void sig_in(BIO* b); @@ -287,7 +287,7 @@ static int ok_read(BIO *b, char *out, int outl) return(ret); } -static int ok_write(BIO *b, char *in, int inl) +static int ok_write(BIO *b, const char *in, int inl) { int ret=0,n,i; BIO_OK_CTX *ctx; @@ -345,7 +345,7 @@ static int ok_write(BIO *b, char *in, int inl) return(ret); } -static long ok_ctrl(BIO *b, int cmd, long num, char *ptr) +static long ok_ctrl(BIO *b, int cmd, long num, void *ptr) { BIO_OK_CTX *ctx; EVP_MD *md; diff --git a/crypto/evp/evp_pbe.c b/crypto/evp/evp_pbe.c index 486b8880ce..187521eb58 100644 --- a/crypto/evp/evp_pbe.c +++ b/crypto/evp/evp_pbe.c @@ -115,7 +115,7 @@ int EVP_PBE_alg_add (int nid, EVP_CIPHER *cipher, EVP_MD *md, EVP_PBE_KEYGEN *keygen) { EVP_PBE_CTL *pbe_tmp; - if (!pbe_algs) pbe_algs = sk_new (pbe_cmp); + if (!pbe_algs) pbe_algs = sk_new ((int (*)())pbe_cmp); if (!(pbe_tmp = (EVP_PBE_CTL*) Malloc (sizeof(EVP_PBE_CTL)))) { EVPerr(EVP_F_EVP_PBE_ALG_ADD,ERR_R_MALLOC_FAILURE); return 0; diff --git a/crypto/evp/evp_pkey.c b/crypto/evp/evp_pkey.c index 4ab091fa56..aada99f747 100644 --- a/crypto/evp/evp_pkey.c +++ b/crypto/evp/evp_pkey.c @@ -193,12 +193,12 @@ EVP_PKEY *EVP_PKCS82PKEY (PKCS8_PRIV_KEY_INFO *p8) EVP_PKEY_assign_DSA(pkey, dsa); BN_CTX_free (ctx); - if(ndsa) sk_pop_free(ndsa, ASN1_TYPE_free); + if(ndsa) sk_pop_free(ndsa, (void(*)(void *)) ASN1_TYPE_free); else ASN1_INTEGER_free(privkey); break; dsaerr: BN_CTX_free (ctx); - sk_pop_free(ndsa, ASN1_TYPE_free); + sk_pop_free(ndsa, (void(*)(void *)) ASN1_TYPE_free); DSA_free(dsa); EVP_PKEY_free(pkey); return NULL; @@ -367,11 +367,11 @@ static int dsa_pkey2pkcs8(PKCS8_PRIV_KEY_INFO *p8, EVP_PKEY *pkey) &p8->pkey->value.octet_string->length)) { EVPerr(EVP_F_EVP_PKEY2PKCS8,ERR_R_MALLOC_FAILURE); - sk_pop_free(ndsa, ASN1_TYPE_free); + sk_pop_free(ndsa, (void(*)(void *)) ASN1_TYPE_free); M_ASN1_INTEGER_free(prkey); return 0; } - sk_pop_free(ndsa, ASN1_TYPE_free); + sk_pop_free(ndsa, (void(*)(void *)) ASN1_TYPE_free); break; case PKCS8_EMBEDDED_PARAM: @@ -395,11 +395,11 @@ static int dsa_pkey2pkcs8(PKCS8_PRIV_KEY_INFO *p8, EVP_PKEY *pkey) &p8->pkey->value.octet_string->length)) { EVPerr(EVP_F_EVP_PKEY2PKCS8,ERR_R_MALLOC_FAILURE); - sk_pop_free(ndsa, ASN1_TYPE_free); + sk_pop_free(ndsa, (void(*)(void *)) ASN1_TYPE_free); M_ASN1_INTEGER_free (prkey); return 0; } - sk_pop_free(ndsa, ASN1_TYPE_free); + sk_pop_free(ndsa, (void(*)(void *)) ASN1_TYPE_free); break; } return 1; |