summaryrefslogtreecommitdiff
path: root/sys-apps/ifplugd/files/ifplugd-0.28-noip.patch
diff options
context:
space:
mode:
Diffstat (limited to 'sys-apps/ifplugd/files/ifplugd-0.28-noip.patch')
-rw-r--r--sys-apps/ifplugd/files/ifplugd-0.28-noip.patch21
1 files changed, 21 insertions, 0 deletions
diff --git a/sys-apps/ifplugd/files/ifplugd-0.28-noip.patch b/sys-apps/ifplugd/files/ifplugd-0.28-noip.patch
new file mode 100644
index 000000000000..5daa4534eb49
--- /dev/null
+++ b/sys-apps/ifplugd/files/ifplugd-0.28-noip.patch
@@ -0,0 +1,21 @@
+[PATCH] Allow ifplugd to run when no TCP/IP is available
+
+This simple patch create AF_LOCAL socket instead of AF_INET so if TCP/IP
+is not linked into kernel it still works.
+
+Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>
+
+---
+
+diff -urNp ifplugd-0.28.org/src/ifplugd.c ifplugd-0.28/src/ifplugd.c
+--- ifplugd-0.28.org/src/ifplugd.c 2005-06-04 22:21:51.000000000 +0300
++++ ifplugd-0.28/src/ifplugd.c 2007-10-30 05:22:53.000000000 +0200
+@@ -409,7 +409,7 @@ void work(void) {
+ break;
+ }
+
+- if ((fd = socket(AF_INET, SOCK_DGRAM, 0)) < 0) {
++ if ((fd = socket(AF_LOCAL, SOCK_DGRAM, 0)) < 0) {
+ daemon_log(LOG_ERR, "socket(): %s", strerror(errno));
+ goto finish;
+ }