diff options
author | raniervf <ranier_gyn@hotmail.com> | 2019-11-16 08:28:00 +1000 |
---|---|---|
committer | Pauli <paul.dale@oracle.com> | 2019-11-16 08:29:26 +1000 |
commit | 4bac25e1115b8c613f9fff12b835aca47e2bdef7 (patch) | |
tree | 5f69584794343fc7eb8635a43a80f3ea7edbcd35 /ssl/ssl_ciph.c | |
parent | d7cea0b8f50ee9cc698211f4fbf8ad5fca5812ad (diff) |
Author: raniervf <ranier_gyn@hotmail.com>
Date: Thu Nov 7 18:59:11 2019 -0300
Avoid calling strlen repeatedly in loops.
Reviewed-by: Paul Yang <kaishen.yy@antfin.com>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/10380)
Diffstat (limited to 'ssl/ssl_ciph.c')
-rw-r--r-- | ssl/ssl_ciph.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ssl/ssl_ciph.c b/ssl/ssl_ciph.c index d047b8ff5d..ffdc4eab5b 100644 --- a/ssl/ssl_ciph.c +++ b/ssl/ssl_ciph.c @@ -1581,7 +1581,7 @@ STACK_OF(SSL_CIPHER) *ssl_create_cipher_list(const SSL_METHOD *ssl_method, rule_p++; } - if (ok && (strlen(rule_p) > 0)) + if (ok && (rule_p[0] != '\0')) ok = ssl_cipher_process_rulestr(rule_p, &head, &tail, ca_list, c); OPENSSL_free(ca_list); /* Not needed anymore */ |