Fixed max port number from 65536 to 65535