diff options
| -rw-r--r-- | lib/url.c | 5 | 
1 files changed, 5 insertions, 0 deletions
| @@ -4319,6 +4319,11 @@ static CURLcode parse_remote_port(struct SessionHandle *data,        *portptr = '\0'; /* cut off the name there */        conn->remote_port = curlx_ultous(port);      } +    else if(!port) +      /* Browser behavior adaptation. If there's a colon with no digits after, +         just cut off the name there which makes us ignore the colon and just +         use the default port. Firefox and Chrome both do that. */ +      *portptr = '\0';    }    return CURLE_OK;  } | 
