diff options
author | arved <arved@FreeBSD.org> | 2004-10-17 22:55:09 +0800 |
---|---|---|
committer | arved <arved@FreeBSD.org> | 2004-10-17 22:55:09 +0800 |
commit | 8fe0da85432e5d4b123db5fa25253371f65f55b2 (patch) | |
tree | eaeadf8f999a58f9a17d887beac239b3e2950212 /net | |
parent | 56475009d12447b8d408635b1cab844cb2cc5900 (diff) | |
download | freebsd-ports-gnome-8fe0da85432e5d4b123db5fa25253371f65f55b2.tar.gz freebsd-ports-gnome-8fe0da85432e5d4b123db5fa25253371f65f55b2.tar.zst freebsd-ports-gnome-8fe0da85432e5d4b123db5fa25253371f65f55b2.zip |
Fix kphone, if the machine has multiple interfaces.
Bump PORTREVISION
PR: 71856
Submitted by: Richard Cepas <rch@richard.eu.org>
Diffstat (limited to 'net')
-rw-r--r-- | net/kphone/Makefile | 1 | ||||
-rw-r--r-- | net/kphone/files/patch-dissipate2-siputil.cpp | 33 |
2 files changed, 31 insertions, 3 deletions
diff --git a/net/kphone/Makefile b/net/kphone/Makefile index 8e483a6e7562..660a060f9064 100644 --- a/net/kphone/Makefile +++ b/net/kphone/Makefile @@ -6,6 +6,7 @@ PORTNAME= kphone PORTVERSION= 4.0.3 +PORTREVISION= 1 CATEGORIES= net MASTER_SITES= http://www.wirlab.net/kphone/ diff --git a/net/kphone/files/patch-dissipate2-siputil.cpp b/net/kphone/files/patch-dissipate2-siputil.cpp index c1ff8235e4d3..c6eb2c645edd 100644 --- a/net/kphone/files/patch-dissipate2-siputil.cpp +++ b/net/kphone/files/patch-dissipate2-siputil.cpp @@ -1,5 +1,5 @@ ---- dissipate2/siputil.cpp.orig Thu Mar 4 12:22:57 2004 -+++ dissipate2/siputil.cpp Mon Jul 5 15:05:32 2004 +--- dissipate2/siputil.cpp.orig Sun Oct 17 15:37:31 2004 ++++ dissipate2/siputil.cpp Sun Oct 17 15:37:15 2004 @@ -5,6 +5,9 @@ #include <sys/time.h> #include <sys/errno.h> @@ -99,7 +99,7 @@ if ( if_count == 1 ) { strncpy( if_name[j], netconf.ifc_req[0].ifr_name, 20 ); strncpy( if_addr[j], inet_ntoa(((struct sockaddr_in*)(&netconf.ifc_req[0].ifr_addr))->sin_addr), 20 ); -@@ -120,6 +158,8 @@ +@@ -120,13 +158,15 @@ } } } @@ -108,3 +108,30 @@ if( j == 1 ) { dissipate_our_fqdn = strdup( if_addr[0] ); } else { + default_ifName = getdefaultdev(); +- if( default_ifName != NULL) { ++ /*if( default_ifName != NULL) {*/ + for( i = 0; i < j; i++ ) { +- if( strcmp( if_name[i], default_ifName ) == 0 ) { ++ if( default_ifName != NULL && strcmp( if_name[i], default_ifName ) == 0 ) { + QMessageBox mb( "KPhone", + "KPhone found more than one interface.\n" + "Do you want to use the default interface:\n\n" + +@@ -147,7 +187,7 @@ + } + } + for( i = 0; i < j; i++ ) { +- if( strcmp( if_name[i], default_ifName ) != 0 ) { ++ if(default_ifName == NULL || strcmp( if_name[i], default_ifName ) != 0 ) { + if( i == j-1 ) { + QMessageBox mb( "KPhone", + "Do you want to use " + QString(if_name[i]) + " (IP:\"" + QString(if_addr[i]) + "\")", +@@ -181,7 +221,7 @@ + } + } + } +- } ++ /*}*/ + } + } + |