diff options
author | Arthur de Jong <arthur@arthurdejong.org> | 2010-10-04 21:35:46 +0200 |
---|---|---|
committer | Arthur de Jong <arthur@arthurdejong.org> | 2010-10-04 21:35:46 +0200 |
commit | b7c3c078c873b1596519b661fdc5b35d48794ace (patch) | |
tree | 820602961c5746e09ecae953daf804769358b8a1 /nss/networks.c | |
parent | 4db60137880169354d4596a598509600d125ccaf (diff) |
merge some of the changes for Solaris portability to ease merging, adding --with-pam-seclib-dir, --with-pam-ldap-soname and --with-nss-flavour options and having some auto-detection for SONAMEs and NSS flavour
git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1239 ef36b2f9-881f-0410-afb5-c4e39611909c
Diffstat (limited to 'nss/networks.c')
-rw-r--r-- | nss/networks.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/nss/networks.c b/nss/networks.c index 8273f27..3c7d10f 100644 --- a/nss/networks.c +++ b/nss/networks.c @@ -2,7 +2,7 @@ networks.c - NSS lookup functions for networks database Copyright (C) 2006 West Consulting - Copyright (C) 2006, 2007, 2008 Arthur de Jong + Copyright (C) 2006, 2007, 2008, 2010 Arthur de Jong This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public @@ -99,13 +99,6 @@ static nss_status_t read_netent( return retv; } -nss_status_t _nss_ldap_getnetbyname_r(const char *name,struct netent *result,char *buffer,size_t buflen,int *errnop,int *h_errnop) -{ - NSS_BYNAME(NSLCD_ACTION_NETWORK_BYNAME, - name, - read_netent(fp,result,buffer,buflen,errnop,h_errnop)); -} - /* write an address value */ /* version 2.10 of glibc changed the address from network to host order (changelog entry 2009-07-01) */ @@ -114,6 +107,13 @@ nss_status_t _nss_ldap_getnetbyname_r(const char *name,struct netent *result,cha WRITE_INT32(fp,4); \ WRITE_INT32(fp,htonl(addr)); +nss_status_t _nss_ldap_getnetbyname_r(const char *name,struct netent *result,char *buffer,size_t buflen,int *errnop,int *h_errnop) +{ + NSS_BYNAME(NSLCD_ACTION_NETWORK_BYNAME, + name, + read_netent(fp,result,buffer,buflen,errnop,h_errnop)); +} + /* Note: the af parameter is ignored and is assumed to be AF_INET */ /* TODO: implement handling of af parameter */ nss_status_t _nss_ldap_getnetbyaddr_r(uint32_t addr,int UNUSED(af),struct netent *result,char *buffer,size_t buflen,int *errnop,int *h_errnop) |