commit | dc139e2e6585fdd3ed8d77d41aab85c5c6c98463 | [log] [tgz] |
---|---|---|
author | David Benjamin <davidben@google.com> | Tue Dec 13 14:22:10 2022 -0500 |
committer | Boringssl LUCI CQ <boringssl-scoped@luci-project-accounts.iam.gserviceaccount.com> | Thu Dec 15 20:42:02 2022 +0000 |
tree | b29fba91b74549a2b29a5850b33dd48b51f7e7c9 | |
parent | 42ba95f5c6afcf9105266225341dbe86741b1b9c [diff] |
Fix return value on malloc failure in tree_calculate_user_set. Change-Id: I880dab43471b12c564909fbc00800b8f7a46575f Reviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/55747 Commit-Queue: Bob Beck <bbe@google.com> Reviewed-by: Bob Beck <bbe@google.com>
diff --git a/crypto/x509v3/pcy_tree.c b/crypto/x509v3/pcy_tree.c index 44ade30..7211e01 100644 --- a/crypto/x509v3/pcy_tree.c +++ b/crypto/x509v3/pcy_tree.c
@@ -646,7 +646,7 @@ if (!tree->user_policies) { tree->user_policies = sk_X509_POLICY_NODE_new_null(); if (!tree->user_policies) { - return 1; + return 0; } } if (!sk_X509_POLICY_NODE_push(tree->user_policies, node)) {