Ed Swierk wrote: > On Wed, 2009-07-22 at 20:57 +0200, Jan Kiszka wrote: >> Nice. I noticed this, too, and shortly thought about some possible >> fixes. Don't know why I dropped it again. Anyway, your approach looks >> straightforward. Please rebase over git head, and I will happily test >> and ack it! > > FYI there are two other things that tend to break on laptops especially: > > - If the system clock jumps backwards, functions that rely on > gettimeofday() for computing a time interval get confused. > gettimeofday() should be replaced with clock_gettime(CLOCK_MONOTONIC). > Hopefully all Unixy platforms support it? You mean that gettimeofday in updtime? Yes, that's only for timeout calculation IIRC and should be converted. Patch welcome. Are there more? I didn't find any on quick scan. > > - Storing the address of some random host interface in our_addr is bad > for the same reason as storing the address of the DNS server. > Fortunately most references to our_addr are in dead code, and the > remaining ones are questionable. True. I shortly thought about ripping all those historic UDP protocol emulations out, but then I didn't feel brave enough. I couldn't asses if they are still of any use for some qemu people (namely it's CUSEEME, the rest is disabled anyway). But maybe it's worth posting another cleanup patch. > > Anyway, here's the updated patch for the DNS issue. Thanks, will test. Jan