diff options
author | Jonas Maebe <jonas.maebe@elis.ugent.be> | 2013-12-08 17:16:12 +0100 |
---|---|---|
committer | Kurt Roeckx <kurt@roeckx.be> | 2014-08-15 22:38:05 +0200 |
commit | 4e64f671c97650b060f20b6d930a88f1a2a306f7 (patch) | |
tree | ea4b7c26e6cb79b87249c8725fc76dba50eded56 /crypto | |
parent | 1c4b688cb45a912d25d839f8ed6287e610352f57 (diff) |
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>
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/bio/bss_rtcp.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/crypto/bio/bss_rtcp.c b/crypto/bio/bss_rtcp.c index 7dae485564..d0cd1a9680 100644 --- a/crypto/bio/bss_rtcp.c +++ b/crypto/bio/bss_rtcp.c @@ -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; |