mirror of
https://github.com/zeek/zeek.git
synced 2025-10-08 09:38:19 +00:00
migrate to differentiated vector "At" accessors to support future efficiency
This commit is contained in:
parent
bc4a6c0d07
commit
0118b6ee38
15 changed files with 91 additions and 89 deletions
|
@ -37,7 +37,7 @@ STACK_OF(X509)* x509_get_untrusted_stack(zeek::VectorVal* certs_vec)
|
|||
|
||||
for ( int i = 1; i < (int) certs_vec->Size(); ++i ) // start at 1 - 0 is host cert
|
||||
{
|
||||
const auto& sv = certs_vec->At(i);
|
||||
auto sv = certs_vec->ValAt(i);
|
||||
|
||||
if ( ! sv )
|
||||
continue;
|
||||
|
@ -232,7 +232,7 @@ function x509_ocsp_verify%(certs: x509_opaque_vector, ocsp_reply: string, root_c
|
|||
|
||||
// host certificate
|
||||
unsigned int index = 0; // to prevent overloading to 0pointer
|
||||
const auto& sv = certs_vec->At(index);
|
||||
auto sv = certs_vec->ValAt(index);
|
||||
if ( ! sv )
|
||||
{
|
||||
zeek::emit_builtin_error("undefined value in certificate vector");
|
||||
|
@ -518,7 +518,7 @@ function x509_verify%(certs: x509_opaque_vector, root_certs: table_string_of_str
|
|||
|
||||
// host certificate
|
||||
unsigned int index = 0; // to prevent overloading to 0pointer
|
||||
const auto& sv = certs_vec->At(index);
|
||||
auto sv = certs_vec->ValAt(index);
|
||||
if ( !sv )
|
||||
{
|
||||
zeek::emit_builtin_error("undefined value in certificate vector");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue