fs newcell mostly-broken

Love lha at stacken.kth.se
Mon Jul 9 05:34:00 CEST 2001


Nickolai Zeldovich <kolya at mit.edu> writes:

> At the moment, "fs newcell" in arla sets the "name" field of the
> cell_db_entry's to NULL.  This causes updatehosts() to crash when
> trying to strcmp the host fields in host_sort().
> 
> The patch below changes host_sort() to compare based on IP address
> rather than hostname -- the actual ordering doesn't really matter,
> as far as I can tell.

The idea is to "sort" the ones with that are valid first (have uptodate dns
information), so we can count the "active" hosts later. So you don't even
need to to htonl there either, since we just want to compare something that
does't changes when qsort is running.

Love





More information about the Arla-drinkers mailing list