Fix crash when retrieving large networks entries

If NSS_STATUS_TRYAGAIN is returned from read_one_hostent or
read_one_netent then fp will be closed and function tio_skipall will be
called with NULL pointer.
It could happend in functions:
    _nss_ldap_getnetbyname_r
    _nss_ldap_getnetbyaddr_r
    _nss_ldap_gethostbyname2_r
    _nss_ldap_gethostbyaddr_r

Fixes r548 (aka afd5d9b).