[Kde-hardware-devel] Bug in Solid::Control::NetworkInterface

Christopher Blauvelt cblauvelt at gmail.com
Thu Mar 6 04:58:41 CET 2008


Background:
eth0: ethernet
eth1: wifi

I'm using knetworkmanager from kde3 to connect to the internet and I'm
connected to a wifi network.
Whenever I use create an iface with uni ==
"org.freedesktop.NetworkManager/Devices/eth0"
and run: "iface.networks()" it would kill my connection and knetworkmanager
would re-create the wifi connection.

I was looking through 'kdebase/workspace/solid/networkmanager-0.6
/NetworkManager-networkinterface.cpp and noticed this at lines 183-187:
if (d->type == Solid::Control::NetworkInterface::Ieee8023)
{
    net = new NMNetwork(uni);
    net->setActivated(true);
}


What I believe is happening is my ethernet is becoming the active device
through these lines.  NetworkManager daemon automatically senses that there
is no carrier and switches back to my wireless connection.

I need to be able to use this function as it allows me to parse available
networks on wifi connections.  It also doesn't seem right to me that a
network is created and then explicitly made active.  Could this be
accomplished outside this function and only after a check that the interface
is the current active interface?  Automatically connecting to the network
seems to be making the assumption that by creating the network, you
automatically want to connect to it which isn't always correct (at least not
in my case :)

Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/kde-hardware-devel/attachments/20080305/09b84882/attachment.html 


More information about the Kde-hardware-devel mailing list