Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 14 Dec 2021 01:22:07 GMT
From:      Cy Schubert <cy@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 27c009fc8826 - stable/12 - ip_log: remove set-but-not-unused vars
Message-ID:  <202112140122.1BE1M7ce065022@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/12 has been updated by cy:

URL: https://cgit.FreeBSD.org/src/commit/?id=27c009fc8826cc2bd359fb56ffd62e111c0ffa44

commit 27c009fc8826cc2bd359fb56ffd62e111c0ffa44
Author:     Cy Schubert <cy@FreeBSD.org>
AuthorDate: 2021-12-11 05:11:45 +0000
Commit:     Cy Schubert <cy@FreeBSD.org>
CommitDate: 2021-12-14 01:19:01 +0000

    ip_log: remove set-but-not-unused vars
    
    (cherry picked from commit 664882ab168f7328c23ceaadb473dab794f835d8)
---
 sys/contrib/ipfilter/netinet/ip_log.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sys/contrib/ipfilter/netinet/ip_log.c b/sys/contrib/ipfilter/netinet/ip_log.c
index 7a80b3e0d4e7..0f31b9983551 100644
--- a/sys/contrib/ipfilter/netinet/ip_log.c
+++ b/sys/contrib/ipfilter/netinet/ip_log.c
@@ -666,7 +666,7 @@ ipf_log_read(softc, unit, uio)
 	struct uio *uio;
 {
 	ipf_log_softc_t *softl = softc->ipf_log_soft;
-	size_t dlen, copied;
+	size_t dlen;
 	int error = 0;
 	iplog_t *ipl;
 	SPL_INT(s);
@@ -738,7 +738,7 @@ ipf_log_read(softc, unit, uio)
 	uio->uio_rw = UIO_READ;
 # endif
 
-	for (copied = 0; (ipl = softl->iplt[unit]) != NULL; copied += dlen) {
+	for (; (ipl = softl->iplt[unit]) != NULL;) {
 		dlen = ipl->ipl_dsize;
 		if (dlen > uio->uio_resid)
 			break;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202112140122.1BE1M7ce065022>