summaryrefslogtreecommitdiffstats
path: root/crypto/evp
diff options
context:
space:
mode:
authorBen Laurie <ben@openssl.org>2011-06-09 16:03:18 +0000
committerBen Laurie <ben@openssl.org>2011-06-09 16:03:18 +0000
commit78ef9b020522ee84e3a0b23cb870d7a964f110c7 (patch)
treed4e1f57f8eb094a4e62cf61846b4468881ba74ea /crypto/evp
parented9b0e5cba9ddc41e7b902d925c5b1b836ada366 (diff)
Fix warnings.
Diffstat (limited to 'crypto/evp')
-rw-r--r--crypto/evp/p_sign.c4
-rw-r--r--crypto/evp/p_verify.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/crypto/evp/p_sign.c b/crypto/evp/p_sign.c
index ba3596bc09..dfa48c157c 100644
--- a/crypto/evp/p_sign.c
+++ b/crypto/evp/p_sign.c
@@ -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 int m_len;
- int i,ok=0,v;
+ int i=0,ok=0,v;
EVP_MD_CTX tmp_ctx;
+ EVP_PKEY_CTX *pkctx = NULL;
*siglen=0;
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)
{
- EVP_PKEY_CTX *pkctx = NULL;
size_t sltmp = (size_t)EVP_PKEY_size(pkey);
i = 0;
pkctx = EVP_PKEY_CTX_new(pkey, NULL);
diff --git a/crypto/evp/p_verify.c b/crypto/evp/p_verify.c
index d43f86e823..5f5c409f45 100644
--- a/crypto/evp/p_verify.c
+++ b/crypto/evp/p_verify.c
@@ -67,8 +67,9 @@ int EVP_VerifyFinal(EVP_MD_CTX *ctx, const unsigned char *sigbuf,
{
unsigned char m[EVP_MAX_MD_SIZE];
unsigned int m_len;
- int i,ok=0,v;
+ int i=-1,ok=0,v;
EVP_MD_CTX tmp_ctx;
+ EVP_PKEY_CTX *pkctx = NULL;
EVP_MD_CTX_init(&tmp_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)
{
- EVP_PKEY_CTX *pkctx = NULL;
i = -1;
pkctx = EVP_PKEY_CTX_new(pkey, NULL);
if (!pkctx)