Bug#1038899: bookworm-pu: package nfdump/1.7.1-2+deb12u1
Package: release.debian.org
Severity: normal
Tags: bookworm
User: release.debian.org@packages.debian.org
Usertags: pu
X-Debbugs-Cc: nfdump@packages.debian.org
Control: affects -1 + src:nfdump
[ Reason ]
This update fixes two errors reported in #1038644
- a segfault when using a particular option
- a wrong 'failed' indication in the sysvinit initscript
The segfault fix is straight forward and just an error in the option
parsing.
[ Impact ]
nfcapd cannot repeat the packets received to another receiver
[ Tests ]
The same fix has been uploaded to 1.7.1-3 in unstable and the reporter
has verified the fix.
[ Risks ]
Fairly minor risk, the option parsing change has been part of an upstream
release (but mixed with a complete rewrite of the actual repeater code, so
it cannot be cherry-picked).
[ Checklist ]
[X] *all* changes are documented in the d/changelog
[X] I reviewed all changes and I approve them
[X] attach debdiff against the package in (old)stable
[X] the issue is verified as fixed in unstable
[ Changes ]
In addition debian/gbp.conf has been changed to point to the debian/bullseye
branch.
[ Other info ]
-
diff -Nru nfdump-1.7.1/debian/changelog nfdump-1.7.1/debian/changelog
--- nfdump-1.7.1/debian/changelog 2023-01-05 12:35:34.000000000 +0100
+++ nfdump-1.7.1/debian/changelog 2023-06-22 22:18:53.000000000 +0200
@@ -1,3 +1,12 @@
+nfdump (1.7.1-2+deb12u1) bookworm; urgency=medium
+
+ * [8554dec3] Fix init script to return success when process has started.
+ Thanks to Yury Shevchuk
+ * [c9d7e789] Fix segfault in getopt parsing for -R (Closes: #1038644)
+ * [eb140f97] d/gbp.conf: set debian branch
+
+ -- Bernhard Schmidt <berni@debian.org> Thu, 22 Jun 2023 22:18:53 +0200
+
nfdump (1.7.1-2) unstable; urgency=medium
* [64bef089] Add tzdata build dependency (Closes: #1027379)
diff -Nru nfdump-1.7.1/debian/gbp.conf nfdump-1.7.1/debian/gbp.conf
--- nfdump-1.7.1/debian/gbp.conf 2023-01-05 12:35:34.000000000 +0100
+++ nfdump-1.7.1/debian/gbp.conf 2023-06-22 22:18:53.000000000 +0200
@@ -2,7 +2,7 @@
[DEFAULT]
# the default branch for the debian patch:
-debian-branch = unstable
+debian-branch = debian/bookworm
# use pristine-tar:
pristine-tar = True
diff -Nru nfdump-1.7.1/debian/nfdump.init nfdump-1.7.1/debian/nfdump.init
--- nfdump-1.7.1/debian/nfdump.init 2023-01-05 12:35:34.000000000 +0100
+++ nfdump-1.7.1/debian/nfdump.init 2023-06-22 22:18:53.000000000 +0200
@@ -58,19 +58,27 @@
fi
local PIDFILE="$PIDDIR$INSTANCE.pid"
+ # Check if process is already running
start-stop-daemon --start --quiet \
--pidfile "$PIDFILE" --exec "$NFCAPD" --test > /dev/null \
|| return 1
+
+ # Start process
start-stop-daemon --start --quiet \
--pidfile "$PIDFILE" \
--exec "$NFCAPD" -- \
-D -P "$PIDFILE" \
$options \
|| return 2
+
+ # Wait for 1 sec and check again if process has started successfully
sleep 1
start-stop-daemon --start --quiet \
--pidfile "$PIDFILE" --exec "$NFCAPD" --test > /dev/null \
&& return 2
+
+ # All good, return 0
+ return 0
}
# Stop a nfcapd instance
diff -Nru nfdump-1.7.1/debian/patches/fix-segfault-in-getopt.patch nfdump-1.7.1/debian/patches/fix-segfault-in-getopt.patch
--- nfdump-1.7.1/debian/patches/fix-segfault-in-getopt.patch 1970-01-01 01:00:00.000000000 +0100
+++ nfdump-1.7.1/debian/patches/fix-segfault-in-getopt.patch 2023-06-22 22:18:53.000000000 +0200
@@ -0,0 +1,11 @@
+--- a/src/nfcapd/nfcapd.c
++++ b/src/nfcapd/nfcapd.c
+@@ -605,7 +605,7 @@
+ metricSocket = NULL;
+ metricInterval = 60;
+
+- while ((c = getopt(argc, argv, "46B:b:C:DeEf:g:hI:i:jJ:l:m:M:n:p:P:rRs:S:t:T:u:vVw:x:yzZ")) != EOF) {
++ while ((c = getopt(argc, argv, "46B:b:C:DeEf:g:hI:i:jJ:l:m:M:n:p:P:rR:s:S:t:T:u:vVw:x:yzZ")) != EOF) {
+ switch (c) {
+ case 'h':
+ usage(argv[0]);
diff -Nru nfdump-1.7.1/debian/patches/series nfdump-1.7.1/debian/patches/series
--- nfdump-1.7.1/debian/patches/series 1970-01-01 01:00:00.000000000 +0100
+++ nfdump-1.7.1/debian/patches/series 2023-06-22 22:18:53.000000000 +0200
@@ -0,0 +1 @@
+fix-segfault-in-getopt.patch
Reply to: