Fix some malloc error handling.
Thanks to Tom Thorogood for catching this. Change-Id: I09fa5d9822b9ba13b106add251e26c6ebee21b03 Reviewed-on: https://boringssl-review.googlesource.com/29825 Reviewed-by: Tom Thorogood <me+google@tomthorogood.co.uk> Reviewed-by: Steven Valdez <svaldez@chromium.org> Reviewed-by: David Benjamin <davidben@google.com> Commit-Queue: David Benjamin <davidben@google.com> CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
This commit is contained in:
parent
861abccb95
commit
8d1203d6c5
@ -2057,8 +2057,8 @@ int SSL_CTX_add_cert_compression_alg(SSL_CTX *ctx, uint16_t alg_id,
|
|||||||
if (!PushToStack(ctx->cert_compression_algs.get(), std::move(alg))) {
|
if (!PushToStack(ctx->cert_compression_algs.get(), std::move(alg))) {
|
||||||
if (sk_CertCompressionAlg_num(ctx->cert_compression_algs.get()) == 0) {
|
if (sk_CertCompressionAlg_num(ctx->cert_compression_algs.get()) == 0) {
|
||||||
ctx->cert_compression_algs.reset();
|
ctx->cert_compression_algs.reset();
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
|
Loading…
Reference in New Issue
Block a user