Some clean-up for LAN_discovery.c

If we want the first interface that is not "lo", then we need at most 2 interfaces to select from (interface names are unique). 

We want the true "count" as returned by the SIOCGIFCONF system call, not the one we guess it to be.

Finally, account for the possible case that there are 0 interfaces.