mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-20 22:59:34 -05:00
ITS#5436: make htons() port number unsigned
This commit is contained in:
parent
8df3224ccf
commit
c55a06254f
1 changed files with 1 additions and 1 deletions
|
|
@ -575,7 +575,7 @@ ldap_connect_to_host(LDAP *ld, Sockbuf *sb,
|
||||||
|
|
||||||
(void)memset((char *)&sin, '\0', sizeof sin);
|
(void)memset((char *)&sin, '\0', sizeof sin);
|
||||||
sin.sin_family = AF_INET;
|
sin.sin_family = AF_INET;
|
||||||
sin.sin_port = htons((short) port);
|
sin.sin_port = htons((unsigned short) port);
|
||||||
|
|
||||||
if( use_hp ) {
|
if( use_hp ) {
|
||||||
AC_MEMCPY( &sin.sin_addr, hp->h_addr_list[i],
|
AC_MEMCPY( &sin.sin_addr, hp->h_addr_list[i],
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue