mirror of
https://github.com/php/php-src.git
synced 2024-12-11 10:54:47 +08:00
some FTP servers return 32bit port numbers.
This commit is contained in:
parent
3340e82508
commit
4368b8e4ac
@ -602,7 +602,7 @@ ftp_pasv(ftpbuf_t *ftp, int pasv)
|
||||
n++;
|
||||
}
|
||||
|
||||
sin6->sin6_port = htons((unsigned short) strtol(ptr, &endptr, 10));
|
||||
sin6->sin6_port = htons((unsigned short) strtoul(ptr, &endptr, 10));
|
||||
if (ptr == endptr || *endptr != delimiter)
|
||||
return 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user