mirror of
https://github.com/openssl/openssl.git
synced 2024-11-25 11:03:37 +08:00
Make disabling last cipher work.
This commit is contained in:
parent
398e99fe5e
commit
7cb472bd0d
@ -954,7 +954,7 @@ static void ssl_cipher_apply_rule(unsigned long cipher_id,
|
||||
int rule, int strength_bits,
|
||||
CIPHER_ORDER **head_p, CIPHER_ORDER **tail_p)
|
||||
{
|
||||
CIPHER_ORDER *head, *tail, *curr, *curr2, *last;
|
||||
CIPHER_ORDER *head, *tail, *curr, *next, *last;
|
||||
const SSL_CIPHER *cp;
|
||||
int reverse = 0;
|
||||
|
||||
@ -971,21 +971,25 @@ static void ssl_cipher_apply_rule(unsigned long cipher_id,
|
||||
|
||||
if (reverse)
|
||||
{
|
||||
curr = tail;
|
||||
next = tail;
|
||||
last = head;
|
||||
}
|
||||
else
|
||||
{
|
||||
curr = head;
|
||||
next = head;
|
||||
last = tail;
|
||||
}
|
||||
|
||||
curr2 = curr;
|
||||
curr = NULL;
|
||||
for (;;)
|
||||
{
|
||||
if ((curr == NULL) || (curr == last)) break;
|
||||
curr = curr2;
|
||||
curr2 = reverse ? curr->prev : curr->next;
|
||||
if (curr == last) break;
|
||||
|
||||
curr = next;
|
||||
|
||||
if (curr == NULL) break;
|
||||
|
||||
next = reverse ? curr->prev : curr->next;
|
||||
|
||||
cp = curr->cipher;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user