User-Agent: Mozilla/5.0 (X11; U; Linux i686; de; rv:1.9) Gecko/2008051202 Firefox/2.0.0.3 Build Identifier: the weather plugin seems to cache network configuration. I've start the plugin on a network 192.168.0.0/24 with a DNS server 192.168.0.1. After suspending the machine and waking up on a network 192.168.1.0./24 with a DNS server 192.168.1.1 the plugin still tries to reach the nameserver 192.168.0.1. A restart of the plugin fixes it. so the network configuration is okay. I found out about by tracing the process with strace. Used xfce-weather-plugin 0.6.2-1 (Debian lenny) Reproducible: Always Steps to Reproduce: 1. start the plugin in network A, with local nameserver 2. suspend machine 3. wake up in another network B (different nameserver) Actual Results: plugin does not reach the server for retrieving weather informationen Expected Results: see information about the weather
FYI, the solution to this is to refresh nameserver info, which is cached by the libc. Doing this is quite easy: #include <netinet/in.h> #include <arpa/nameser.h> #include <resolv.h> update_network_stuff() { ... res_init(); do_network_stuff(); ... } HTH
Created attachment 1647 Candidate patch This patch adds a call to res_init() when needed (resolv.conf changed). It also modifies configure.in.in to link against libresolv. It should fix this bug :)
Created attachment 2396 The patch Same patch, without autotools changes
Re-assigning to Colin Leroy who is the new maintainer of the plugin.
Patch applied in svn r7526.