2908dd141f
bssl::UniquePtr and FOO_up_ref do not play well together. Add a helper to simplify this. This allows us to write things like: foo->cert = UpRef(bar->cert); instead of: if (bar->cert) { X509_up_ref(bar->cert.get()); } foo->cert.reset(bar->cert.get()); This also plays well with PushToStack. To append something to a stack while taking a reference, it's just: PushToStack(certs, UpRef(cert)) Change-Id: I99ae8de22b837588a2d8ffb58f86edc1d03ed46a Reviewed-on: https://boringssl-review.googlesource.com/29584 Commit-Queue: David Benjamin <davidben@google.com> CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org> Reviewed-by: Adam Langley <agl@google.com> |
||
---|---|---|
.. | ||
bn_div_corpus | ||
bn_mod_exp_corpus | ||
cert_corpus | ||
client_corpus | ||
client_corpus_no_fuzzer_mode | ||
dtls_client_corpus | ||
dtls_server_corpus | ||
pkcs8_corpus | ||
pkcs12_corpus | ||
privkey_corpus | ||
read_pem_corpus | ||
server_corpus | ||
server_corpus_no_fuzzer_mode | ||
session_corpus | ||
spki_corpus | ||
ssl_ctx_api_corpus | ||
bn_div.cc | ||
bn_mod_exp.cc | ||
cert.cc | ||
client.cc | ||
CMakeLists.txt | ||
dtls_client.cc | ||
dtls_server.cc | ||
minimise_corpuses.sh | ||
pkcs8.cc | ||
pkcs12.cc | ||
privkey.cc | ||
read_pem.cc | ||
refresh_ssl_corpora.sh | ||
server.cc | ||
session.cc | ||
spki.cc | ||
ssl_ctx_api.cc |