summaryrefslogtreecommitdiff
path: root/net/kdenetwork3/patches/patch-ad
diff options
context:
space:
mode:
Diffstat (limited to 'net/kdenetwork3/patches/patch-ad')
-rw-r--r--net/kdenetwork3/patches/patch-ad70
1 files changed, 0 insertions, 70 deletions
diff --git a/net/kdenetwork3/patches/patch-ad b/net/kdenetwork3/patches/patch-ad
deleted file mode 100644
index b3f486cb02b..00000000000
--- a/net/kdenetwork3/patches/patch-ad
+++ /dev/null
@@ -1,70 +0,0 @@
-$NetBSD: patch-ad,v 1.4 2006/03/30 02:47:01 markd Exp $
-
---- kppp/pppstats.cpp.orig 2006-03-17 23:12:34.000000000 +1300
-+++ kppp/pppstats.cpp
-@@ -54,7 +54,11 @@
- #include <arpa/inet.h>
- #include <unistd.h>
- #include <netinet/in.h>
-+#ifdef __DragonFly__
-+#include <net/ppp_layer/ppp_defs.h>
-+#else
- #include <net/ppp_defs.h>
-+#endif
-
- #include "config.h"
- #include "pppstats.h"
-@@ -70,6 +74,9 @@
- #ifdef HAVE_LINUX_IF_PPP_H
- #include <linux/if.h>
- #include <linux/if_ppp.h>
-+ #elif defined(__DragonFly__)
-+ #include <net/if.h>
-+ #include <net/ppp/if_ppp.h>
- #endif
- #else
- #include <net/if.h>
-@@ -218,26 +225,29 @@ bool PPPStats::initStats() {
-
- strlcpy(ifr.ifr_name, unitName, sizeof(ifr.ifr_name));
-
-+ local_ip_address = "";
- if (ioctl(s, SIOCGIFADDR, &ifr) < 0) {
-- }
-+ kdDebug(5002) << "Cannot get ip address" << endl;
-+ } else {
-+ sinp = (struct sockaddr_in*)&ifr.ifr_addr;
-
-- sinp = (struct sockaddr_in*)&ifr.ifr_addr;
-+ if(sinp->sin_addr.s_addr)
-+ local_ip_address = inet_ntoa(sinp->sin_addr);
-
-- if(sinp->sin_addr.s_addr)
-- local_ip_address = inet_ntoa(sinp->sin_addr);
-- else
-- local_ip_address = "";
-- kdDebug(5002) << "Local IP: " << local_ip_address << endl;
-+ kdDebug(5002) << "Local IP: " << local_ip_address << endl;
-+ }
-
-- (void) ioctl(s, SIOCGIFDSTADDR, &ifr);
-+ remote_ip_address = "";
-+ if (ioctl(s, SIOCGIFDSTADDR, &ifr) < 0) {
-+ kdDebug(5002) << "Cannot get remote ip address" << endl;
-+ } else {
-+ sinp = (struct sockaddr_in*)&ifr.ifr_dstaddr;
-
-- sinp = (struct sockaddr_in*)&ifr.ifr_dstaddr;
-+ if(sinp->sin_addr.s_addr)
-+ remote_ip_address = inet_ntoa(sinp->sin_addr);
-
-- if(sinp->sin_addr.s_addr)
-- remote_ip_address = inet_ntoa(sinp->sin_addr);
-- else
-- remote_ip_address = "";
-- kdDebug(5002) << "Remote IP: " << remote_ip_address << endl;
-+ kdDebug(5002) << "Remote IP: " << remote_ip_address << endl;
-+ }
-
- return true;
-