Arthur de Jong

Open Source / Free Software developer

summaryrefslogtreecommitdiffstats
path: root/nss/services.c
diff options
context:
space:
mode:
authorArthur de Jong <arthur@arthurdejong.org>2010-07-27 08:26:08 +0200
committerArthur de Jong <arthur@arthurdejong.org>2010-07-27 08:26:08 +0200
commit2ea91ea150376c63f39b0b10f6b95306ecd8a04b (patch)
treede1be015a980ec64d6446f563fb58d3371ef0544 /nss/services.c
parent84a0ecf4724cc57f30d8994cfce532c9de7702f0 (diff)
use htons() instead of ntohs() (thanks Ted C. Cheng)
git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1167 ef36b2f9-881f-0410-afb5-c4e39611909c
Diffstat (limited to 'nss/services.c')
-rw-r--r--nss/services.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/nss/services.c b/nss/services.c
index c5d2015..e5ae0ae 100644
--- a/nss/services.c
+++ b/nss/services.c
@@ -39,7 +39,7 @@ static enum nss_status read_servent(
READ_BUF_STRINGLIST(fp,result->s_aliases);
/* store port number in network byte order */
READ_TYPE(fp,tmpint32,int32_t);
- result->s_port=ntohs((uint16_t)tmpint32);
+ result->s_port=htons((uint16_t)tmpint32);
READ_BUF_STRING(fp,result->s_proto);
/* we're done */
return NSS_STATUS_SUCCESS;