public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Yaakov Selkowitz <yselkowi@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/tcptrack] rawhide: Fix build with GCC 16
Date: Wed, 16 Sep 2026 11:52:00 GMT [thread overview]
Message-ID: <178955952031.1.6505018519985376188.rpms-tcptrack-55f2548d806e@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/tcptrack
Branch : rawhide
Commit : 55f2548d806e71b2d2a79195f8fbb402d455e4d1
Author : Yaakov Selkowitz <yselkowi@redhat.com>
Date : 2026-09-15T16:01:02-04:00
Stats : +61/-0 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/tcptrack/c/55f2548d806e71b2d2a79195f8fbb402d455e4d1?branch=rawhide
Log:
Fix build with GCC 16
https://github.com/bchretien/tcptrack/pull/15
---
diff --git a/tcptrack-1.4.3-unused-vars.patch b/tcptrack-1.4.3-unused-vars.patch
new file mode 100644
index 0000000..aac18c2
--- /dev/null
+++ b/tcptrack-1.4.3-unused-vars.patch
@@ -0,0 +1,58 @@
+From 26c16305fbb83f87dc0ff3541968e0eca3236456 Mon Sep 17 00:00:00 2001
+From: Chow Loong Jin <hyperair@debian.org>
+Date: Fri, 17 Apr 2026 15:18:09 +0800
+Subject: [PATCH] Drop variables that are set but not used
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Fixes the following error when compiling using gcc 16:
+
+ PacketBuffer.cc: In member function ‘void PacketBuffer::maint_thread_run()’:
+ PacketBuffer.cc:146:21: error: variable ‘qlen’ set but not used [-Werror=unused-but-set-variable=]
+ 146 | int qlen=0;
+ | ^~~~
+ cc1plus: all warnings being treated as errors
+ make[3]: *** [Makefile:453: PacketBuffer.o] Error 1
+ make[3]: *** Waiting for unfinished jobs....
+ TCContainer.cc: In member function ‘void TCContainer::maint_thread_run()’:
+ TCContainer.cc:180:21: error: variable ‘numitems’ set but not used [-Werror=unused-but-set-variable=]
+ 180 | int numitems = 0;
+ | ^~~~~~~~
+ cc1plus: all warnings being treated as errors
+---
+ src/PacketBuffer.cc | 2 --
+ src/TCContainer.cc | 2 --
+ 2 files changed, 4 deletions(-)
+
+diff --git a/src/PacketBuffer.cc b/src/PacketBuffer.cc
+index 6da111f..c167785 100644
+--- a/src/PacketBuffer.cc
++++ b/src/PacketBuffer.cc
+@@ -143,10 +143,8 @@ void PacketBuffer::maint_thread_run()
+ // outq doesn't need locks because this (pb maint thread) is the
+ // only thread that should ever access it.
+ p=NULL;
+- int qlen=0;
+ while( ! outq->empty() )
+ {
+- ++qlen;
+ p=NULL;
+ p=outq->front();
+
+diff --git a/src/TCContainer.cc b/src/TCContainer.cc
+index a3b5b83..043890b 100644
+--- a/src/TCContainer.cc
++++ b/src/TCContainer.cc
+@@ -177,11 +177,9 @@ void TCContainer::maint_thread_run()
+
+ lock();
+
+- int numitems = 0;
+ for( tccmap::iterator i=conhash2.begin(); i!=conhash2.end(); )
+ {
+ TCPConnection *ic=(*i).second;
+- numitems++;
+ ic->recalcAvg();
+
+ // remove closed or stale connections.
diff --git a/tcptrack.spec b/tcptrack.spec
index ece4bff..f5f7153 100644
--- a/tcptrack.spec
+++ b/tcptrack.spec
@@ -12,6 +12,9 @@ Source0: https://github.com/bchretien/tcptrack/archive/v%{version}.tar.gz
# was already reported upstream in https://github.com/bchretien/tcptrack/pull/10/
# line changed
Patch0: https://github.com/bchretien/tcptrack/commit/409007afbce8ec5a81312a2a4123dd83b62b4494.patch#/tcptrack-1.4.3-type-mismatch.patch
+# Drop variables that are set but not used
+# https://github.com/bchretien/tcptrack/pull/15
+Patch1: https://github.com/bchretien/tcptrack/commit/26c16305fbb83f87dc0ff3541968e0eca3236456.patch#/tcptrack-1.4.3-unused-vars.patch
BuildRequires: make
BuildRequires: gcc-c++
reply other threads:[~2026-09-16 11:52 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=178955952031.1.6505018519985376188.rpms-tcptrack-55f2548d806e@fedoraproject.org \
--to=yselkowi@redhat.com \
--cc=git-commits@fedoraproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox