Skip to content

Commit

Permalink
Call EnsureOpenSSLInit from BufferPoolSingleton constructor
Browse files Browse the repository at this point in the history
(cherry picked from commit 617ba30)

Bug: 1462345
Change-Id: If2bb86cdacd2156edc07b441260c86aa4d2ec1dc
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4660070
Commit-Queue: Matt Mueller <mattm@chromium.org>
Auto-Submit: Matt Mueller <mattm@chromium.org>
Commit-Queue: David Benjamin <davidben@chromium.org>
Reviewed-by: David Benjamin <davidben@chromium.org>
Cr-Original-Commit-Position: refs/heads/main@{#1166042}
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4669961
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/branch-heads/5845@{#355}
Cr-Branched-From: 5a5dff6-refs/heads/main@{#1160321}
  • Loading branch information
matt-mueller authored and Chromium LUCI CQ committed Jul 6, 2023
1 parent ce56698 commit ff6c807
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion net/cert/x509_util.cc
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,12 @@ const EVP_MD* ToEVP(DigestAlgorithm alg) {

class BufferPoolSingleton {
public:
BufferPoolSingleton() : pool_(CRYPTO_BUFFER_POOL_new()) {}
BufferPoolSingleton() {
crypto::EnsureOpenSSLInit();

pool_ = CRYPTO_BUFFER_POOL_new();
}

CRYPTO_BUFFER_POOL* pool() { return pool_; }

private:
Expand Down

0 comments on commit ff6c807

Please sign in to comment.