Fix warnings (note that gcc 4.2 has a bug that makes one of its
warnings hard to fix without major surgery).
This commit is contained in:
parent
2b13f80360
commit
19ec2f4194
@ -235,7 +235,7 @@ int PKCS5_v2_PBKDF2_keyivgen(EVP_CIPHER_CTX *ctx, const char *pass, int passlen,
|
|||||||
const unsigned char *pbuf;
|
const unsigned char *pbuf;
|
||||||
int saltlen, iter, plen;
|
int saltlen, iter, plen;
|
||||||
int rv = 0;
|
int rv = 0;
|
||||||
unsigned int keylen;
|
unsigned int keylen = 0;
|
||||||
int prf_nid, hmac_md_nid;
|
int prf_nid, hmac_md_nid;
|
||||||
PBKDF2PARAM *kdf = NULL;
|
PBKDF2PARAM *kdf = NULL;
|
||||||
const EVP_MD *prfmd;
|
const EVP_MD *prfmd;
|
||||||
|
@ -80,8 +80,9 @@ int EVP_SignFinal(EVP_MD_CTX *ctx, unsigned char *sigret, unsigned int *siglen,
|
|||||||
{
|
{
|
||||||
unsigned char m[EVP_MAX_MD_SIZE];
|
unsigned char m[EVP_MAX_MD_SIZE];
|
||||||
unsigned int m_len;
|
unsigned int m_len;
|
||||||
int i,ok=0,v;
|
int i = 0,ok = 0,v;
|
||||||
MS_STATIC EVP_MD_CTX tmp_ctx;
|
MS_STATIC EVP_MD_CTX tmp_ctx;
|
||||||
|
EVP_PKEY_CTX *pkctx = NULL;
|
||||||
|
|
||||||
*siglen=0;
|
*siglen=0;
|
||||||
EVP_MD_CTX_init(&tmp_ctx);
|
EVP_MD_CTX_init(&tmp_ctx);
|
||||||
@ -93,7 +94,6 @@ int EVP_SignFinal(EVP_MD_CTX *ctx, unsigned char *sigret, unsigned int *siglen,
|
|||||||
|
|
||||||
if (ctx->digest->flags & EVP_MD_FLAG_PKEY_METHOD_SIGNATURE)
|
if (ctx->digest->flags & EVP_MD_FLAG_PKEY_METHOD_SIGNATURE)
|
||||||
{
|
{
|
||||||
EVP_PKEY_CTX *pkctx = NULL;
|
|
||||||
size_t sltmp = (size_t)EVP_PKEY_size(pkey);
|
size_t sltmp = (size_t)EVP_PKEY_size(pkey);
|
||||||
i = 0;
|
i = 0;
|
||||||
pkctx = EVP_PKEY_CTX_new(pkey, NULL);
|
pkctx = EVP_PKEY_CTX_new(pkey, NULL);
|
||||||
|
@ -67,8 +67,9 @@ int EVP_VerifyFinal(EVP_MD_CTX *ctx, const unsigned char *sigbuf,
|
|||||||
{
|
{
|
||||||
unsigned char m[EVP_MAX_MD_SIZE];
|
unsigned char m[EVP_MAX_MD_SIZE];
|
||||||
unsigned int m_len;
|
unsigned int m_len;
|
||||||
int i,ok=0,v;
|
int i = 0,ok = 0,v;
|
||||||
MS_STATIC EVP_MD_CTX tmp_ctx;
|
MS_STATIC EVP_MD_CTX tmp_ctx;
|
||||||
|
EVP_PKEY_CTX *pkctx = NULL;
|
||||||
|
|
||||||
EVP_MD_CTX_init(&tmp_ctx);
|
EVP_MD_CTX_init(&tmp_ctx);
|
||||||
if (!EVP_MD_CTX_copy_ex(&tmp_ctx,ctx))
|
if (!EVP_MD_CTX_copy_ex(&tmp_ctx,ctx))
|
||||||
@ -79,7 +80,6 @@ int EVP_VerifyFinal(EVP_MD_CTX *ctx, const unsigned char *sigbuf,
|
|||||||
|
|
||||||
if (ctx->digest->flags & EVP_MD_FLAG_PKEY_METHOD_SIGNATURE)
|
if (ctx->digest->flags & EVP_MD_FLAG_PKEY_METHOD_SIGNATURE)
|
||||||
{
|
{
|
||||||
EVP_PKEY_CTX *pkctx = NULL;
|
|
||||||
i = -1;
|
i = -1;
|
||||||
pkctx = EVP_PKEY_CTX_new(pkey, NULL);
|
pkctx = EVP_PKEY_CTX_new(pkey, NULL);
|
||||||
if (!pkctx)
|
if (!pkctx)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user