Fix getnetbyaddr implementation.
authorUlrich Drepper <drepper@redhat.com>
Wed, 1 Jul 2009 09:42:59 +0000 (02:42 -0700)
committerUlrich Drepper <drepper@redhat.com>
Wed, 1 Jul 2009 09:42:59 +0000 (02:42 -0700)
commit29ba9812bb86bf6da9702f4fbff5cdbb25846401
tree80640cc07ed58cf497a77602a28a75b2504c0a17
parente6bd12ddf72412918fe9002a3e27ecc07775bd64
Fix getnetbyaddr implementation.

There were two problems in the getnetbyaddr implementation.  The type
argument is pretty much useless since (almost) no input file contains
this information and the NSS backends make up the value they fill in
for the n_addrtype field.  Therefore we now declare that passing AF_UNSPEC
is always recognized.  Secondly, the files backend didn't compare the network
numbers with the correct endianess.

Also change getent to take advantage of the type parameter change.
ChangeLog
nss/getent.c
nss/nss_files/files-network.c