diff options
Diffstat (limited to '')
| -rw-r--r-- | src/lib/libssl/ssl_pkt.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/libssl/ssl_pkt.c b/src/lib/libssl/ssl_pkt.c index 31a66753bf..1e0bd83d09 100644 --- a/src/lib/libssl/ssl_pkt.c +++ b/src/lib/libssl/ssl_pkt.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: ssl_pkt.c,v 1.34 2021/01/19 18:57:09 jsing Exp $ */ | 1 | /* $OpenBSD: ssl_pkt.c,v 1.35 2021/02/08 17:18:39 jsing Exp $ */ |
| 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
| 3 | * All rights reserved. | 3 | * All rights reserved. |
| 4 | * | 4 | * |
| @@ -227,14 +227,14 @@ ssl3_read_n(SSL *s, int n, int max, int extend) | |||
| 227 | return -1; | 227 | return -1; |
| 228 | } | 228 | } |
| 229 | 229 | ||
| 230 | if (!s->internal->read_ahead) { | 230 | if (s->internal->read_ahead || SSL_is_dtls(s)) { |
| 231 | /* ignore max parameter */ | ||
| 232 | max = n; | ||
| 233 | } else { | ||
| 234 | if (max < n) | 231 | if (max < n) |
| 235 | max = n; | 232 | max = n; |
| 236 | if (max > (int)(rb->len - rb->offset)) | 233 | if (max > (int)(rb->len - rb->offset)) |
| 237 | max = rb->len - rb->offset; | 234 | max = rb->len - rb->offset; |
| 235 | } else { | ||
| 236 | /* ignore max parameter */ | ||
| 237 | max = n; | ||
| 238 | } | 238 | } |
| 239 | 239 | ||
| 240 | while (left < n) { | 240 | while (left < n) { |
