JPAKE_CTX_new: check for NULL result when allocating ctx
Signed-off-by: Kurt Roeckx <kurt@openssl.org> Reviewed-by: Dr. Stephen Henson <steve@openssl.org>
This commit is contained in:
parent
34374c2d2c
commit
462319c3e9
@ -117,6 +117,8 @@ JPAKE_CTX *JPAKE_CTX_new(const char *name, const char *peer_name,
|
||||
const BIGNUM *secret)
|
||||
{
|
||||
JPAKE_CTX *ctx = OPENSSL_malloc(sizeof *ctx);
|
||||
if (ctx == NULL)
|
||||
return NULL;
|
||||
|
||||
JPAKE_CTX_init(ctx, name, peer_name, p, g, q, secret);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user