Use htonl() rather than htons().
This commit is contained in:
parent
65d748cf46
commit
5ae6fac1d7
@ -1332,7 +1332,7 @@ int StrToPort (char* str, char* proto)
|
||||
|
||||
port = strtol (str, &end, 10);
|
||||
if (end != str)
|
||||
return htons (port);
|
||||
return htonl (port);
|
||||
|
||||
sp = getservbyname (str, proto);
|
||||
if (!sp)
|
||||
|
@ -1332,7 +1332,7 @@ int StrToPort (char* str, char* proto)
|
||||
|
||||
port = strtol (str, &end, 10);
|
||||
if (end != str)
|
||||
return htons (port);
|
||||
return htonl (port);
|
||||
|
||||
sp = getservbyname (str, proto);
|
||||
if (!sp)
|
||||
|
Loading…
Reference in New Issue
Block a user