Browse Source

Patch: Make "listen on any interface" usable

Christoph Biedl 13 years ago
parent
commit
48849acc0a
3 changed files with 18 additions and 1 deletions
  1. 15 0
      debian/patches/20-allow-any-interface.patch
  2. 1 0
      debian/patches/series
  3. 2 1
      debian/softflowd.default

+ 15 - 0
debian/patches/20-allow-any-interface.patch

@@ -0,0 +1,15 @@
+From: Christoph Biedl <debian.packages.hhqj@manchmal.in-ulm.de>
+Subject: Do not leave main loop while listening on "any" interface
+Forwarded: http://lists.mindrot.org/pipermail/netflow-tools/2011-February/000488.html
+
+--- a/softflowd.c
++++ b/softflowd.c
+@@ -1924,7 +1924,7 @@ main(int argc, char **argv)
+ 				logit(LOG_ERR, "Exiting on pcap_dispatch: %s", 
+ 				    pcap_geterr(pcap));
+ 				break;
+-			} else if (r == 0) {
++			} else if (r == 0 && capfile != NULL) {
+ 				logit(LOG_NOTICE, "Shutting down after "
+ 				    "pcap EOF");
+ 				graceful_shutdown_request = 1;

+ 1 - 0
debian/patches/series

@@ -0,0 +1 @@
+20-allow-any-interface.patch

+ 2 - 1
debian/softflowd.default

@@ -3,7 +3,8 @@
 #
 # note: softflowd will not start without an interface configured.
 
-# The interface softflowd listens on.
+# The interface softflowd listens on. You may also use "any" to listen
+# on all interfaces.
 INTERFACE=""
 
 # Further options for softflowd, see "man softflowd" for details.