From 5f55781beb8bfc84412127b3777e1d1d126459b6 Mon Sep 17 00:00:00 2001 From: Arthur de Jong Date: Sun, 16 Dec 2012 15:11:59 +0000 Subject: switch protocol from host byte order to network byte order and switch use of uid_t and gid_t in the protocol to int32 git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1864 ef36b2f9-881f-0410-afb5-c4e39611909c --- nslcd/common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'nslcd/common.c') diff --git a/nslcd/common.c b/nslcd/common.c index ec20693..37542b9 100644 --- a/nslcd/common.c +++ b/nslcd/common.c @@ -165,7 +165,7 @@ int write_address(TFILE *fp,MYLDAP_ENTRY *entry,const char *attr, /* write the address length */ WRITE_INT32(fp,sizeof(struct in_addr)); /* write the address itself (in network byte order) */ - WRITE_TYPE(fp,ipv4addr,struct in_addr); + WRITE(fp,&ipv4addr,sizeof(struct in_addr)); } else if (inet_pton(AF_INET6,addr,&ipv6addr)>0) { @@ -174,7 +174,7 @@ int write_address(TFILE *fp,MYLDAP_ENTRY *entry,const char *attr, /* write the address length */ WRITE_INT32(fp,sizeof(struct in6_addr)); /* write the address itself (in network byte order) */ - WRITE_TYPE(fp,ipv6addr,struct in6_addr); + WRITE(fp,&ipv6addr,sizeof(struct in6_addr)); } else { -- cgit v1.2.3