diff options
author | Hugo Landau <hlandau@openssl.org> | 2023-05-22 14:23:40 +0200 |
---|---|---|
committer | Hugo Landau <hlandau@openssl.org> | 2023-05-24 11:34:55 +0200 |
commit | abbbc06a94cafa7e212bfe7dcbf818ac33d986d3 (patch) | |
tree | 58673e55d818f0c36487a3ffb76ceb7ba0948e7a | |
parent | QUIC: Add to threads sanitizer CI (diff) | |
download | openssl-abbbc06a94cafa7e212bfe7dcbf818ac33d986d3.tar.xz openssl-abbbc06a94cafa7e212bfe7dcbf818ac33d986d3.zip |
Remove an unused variable (clang 16 warning)
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/20856)
-rw-r--r-- | include/internal/ring_buf.h | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/include/internal/ring_buf.h b/include/internal/ring_buf.h index 175f78047f..e7da3b32a0 100644 --- a/include/internal/ring_buf.h +++ b/include/internal/ring_buf.h @@ -102,10 +102,10 @@ static ossl_inline size_t ring_buf_push(struct ring_buf *r, const unsigned char *buf, size_t buf_len) { - size_t pushed = 0, avail, idx, l, i; + size_t pushed = 0, avail, idx, l; unsigned char *start = r->start; - for (i = 0;; ++i) { + for (;;) { avail = ring_buf_avail(r); if (buf_len > avail) buf_len = avail; @@ -113,8 +113,6 @@ static ossl_inline size_t ring_buf_push(struct ring_buf *r, if (buf_len == 0) break; - assert(i < 2); - idx = r->head_offset % r->alloc; l = r->alloc - idx; if (buf_len < l) |