rtcp_new: return failure if allocation of bi->ptr failed
Signed-off-by: Kurt Roeckx <kurt@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org>
This commit is contained in:
parent
1c4b688cb4
commit
4e64f671c9
@ -157,6 +157,8 @@ static int rtcp_new(BIO *bi)
|
||||
bi->num=0;
|
||||
bi->flags = 0;
|
||||
bi->ptr=OPENSSL_malloc(sizeof(struct rpc_ctx));
|
||||
if (bi->ptr == NULL)
|
||||
return(0);
|
||||
ctx = (struct rpc_ctx *) bi->ptr;
|
||||
ctx->filled = 0;
|
||||
ctx->pos = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user