ports/71856: net/kphone startup problem with multiple interfaces (patch)
RiÄardas Äepas
rch at richard.eu.org
Sat Sep 18 09:20:34 UTC 2004
>Number: 71856
>Category: ports
>Synopsis: net/kphone startup problem with multiple interfaces (patch)
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Sat Sep 18 09:20:33 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator: Richard Cepas
>Release: FreeBSD 5.3-BETA2 i386
>Organization:
>Environment:
System: FreeBSD richard.strangled.net 5.3-BETA2 FreeBSD 5.3-BETA2 #3: Sun Sep 5 14:30:41 EEST 2004 rch at richard.strangled.net:/usr/local/obj/usr/src/sys/MYKERNEL i386
>Description:
Doesn't start in case there are 2 network cards attached.
I think getdefaultdev() in dissipate2/siputil.cpp is Linux specific
and always returns NULL. The workaround below lets kphone to start even if
NULL is received from getdefaultdev().
>How-To-Repeat:
Start kphone on box with two NICs.
>Fix:
--- kphone/dissipate2/siputil.cpp.orig2 Mon Sep 13 17:30:46 2004
+++ kphone/dissipate2/siputil.cpp Mon Sep 13 17:44:52 2004
@@ -164,9 +164,9 @@
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" +
@@ -187,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]) + "\")",
@@ -221,7 +221,7 @@
}
}
}
- }
+ /*}*/
}
}
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list