service-discovery-applet shows redundant services when multiple NICs active

Bug #306006 reported by Noel J. Bergman
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
service-discovery-applet (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: service-discovery-applet

I have two network adapters, eth0 and wlan0. They are present on the same subnet and see the same published services. Therefore, avahi-browse shows the services twice, e.g.,

+ wlan0 IPv4 <host> SSH Remote Terminal local
+ eth0 IPv4 <host> SSH Remote Terminal local

The service-discovery-applet populates both into the menu. Since there is no use of the NIC when selecting the outgoing connection, this is not helpful. The service-discovery-applet should populate only one copy into the menu.

Revision history for this message
Noel J. Bergman (noeljb) wrote :

Looking at the code, and I am neither a python expert nor a gtk expert, it appears that a suitable change can be made around line 320 in service-discovery-applet.

The code there is:

 menuitem = gtk.MenuItem(name, False)
 self.zc_types[type].add(menuitem)
 self.zc_services[(interface, protocol, name, type, domain)] = menuitem
 menuitem.connect("activate", self.menuitem_response,interface, protocol, name, type, domain)
 menuitem.show_all()

When we actually connect to a service, the code is:

      self.plugin.plugins[type][0].connect(self.use_host_names, name, type, host, address, port, txts)

with no use of the interface.

It seems to me that we should either modify the menu building code to filter out duplicates, or else put the interface name in the menu if someone thinks it will be significant (which it clearly is not at this time).

Revision history for this message
jorge (xxopxe) wrote :

Agree. In DNS-SD, services are defined at the IP level by a host/port pair. Thus, the service will be accesed according to routing rules, and the interface info is of no use. So, if both interfaces are on the same network, only one entry should be shown.
Though, if both interfaces are on different networks, and both networks happen to have services named the same... Really improvable but I guess the plugin could check the services aren't the same (looking at the addresses), and then tag them with the interface.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.