提交 f1c2a9de 编写于 作者: G Geoff Thorpe

The 'type' parameter, an EVP_MD pointer, represents the type of digest

required as well as a default implementation (when no ENGINE provides a
replacement implementation). This change makes sure the correct
implementation's "init()" handler is used rather than assuming 'type'.
上级 52b66a62
......@@ -189,7 +189,7 @@ int EVP_DigestInit_ex(EVP_MD_CTX *ctx, const EVP_MD *type, ENGINE *impl)
ctx->md_data=OPENSSL_malloc(type->ctx_size);
}
skip_to_init:
return type->init(ctx);
return ctx->digest->init(ctx);
}
int EVP_DigestUpdate(EVP_MD_CTX *ctx, const void *data,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册