mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-05-03 16:28:01 +00:00
BUILD: fd: remove unused variable totlen in fd_write_frag_line()
Ilya reports in GH #1392 that clang 13 complains about totlen being calculated and not used in fd_write_frag_line(), which is true. It's a leftover of some older code.
This commit is contained in:
parent
b5d1141305
commit
87063a7da1
2
src/fd.c
2
src/fd.c
@ -545,7 +545,6 @@ int fd_update_events(int fd, uint evts)
|
||||
ssize_t fd_write_frag_line(int fd, size_t maxlen, const struct ist pfx[], size_t npfx, const struct ist msg[], size_t nmsg, int nl)
|
||||
{
|
||||
struct iovec iovec[32];
|
||||
size_t totlen = 0;
|
||||
size_t sent = 0;
|
||||
int vec = 0;
|
||||
int attempts = 0;
|
||||
@ -572,7 +571,6 @@ ssize_t fd_write_frag_line(int fd, size_t maxlen, const struct ist pfx[], size_t
|
||||
iovec[vec].iov_base = pfx->ptr;
|
||||
iovec[vec].iov_len = MIN(maxlen, pfx->len);
|
||||
maxlen -= iovec[vec].iov_len;
|
||||
totlen += iovec[vec].iov_len;
|
||||
if (iovec[vec].iov_len)
|
||||
vec++;
|
||||
pfx++; npfx--;
|
||||
|
Loading…
Reference in New Issue
Block a user