Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

url: bad --connect-to syntax now returns error #7183

Closed
wants to merge 2 commits into from

Conversation

gunhu
Copy link
Contributor

@gunhu gunhu commented Jun 3, 2021

This PR address bad --connect-to syntax.

Before:

$ curl --connect-to ::curl.se:151.101.66.49 https://curl.se -v
* No valid port number in connect to host string (151.101.66.49)
*   Trying 151.101.194.49...
* TCP_NODELAY set
* Connected to curl.se (151.101.194.49) port 443 (#0)

After:

$ ./src/curl --connect-to ::curl.se:curl.se https://curl.se -v
* No valid port number in connect to host string (curl.se)
* Closing connection -1
curl: (49) No valid port number in connect to host string (curl.se)

As always I'm open to any comment.

$ /usr/bin/perl -I. ./runtests.pl 3020
********* System characteristics ********
* curl 7.77.1-DEV (x86_64-pc-linux-gnu)
* libcurl/7.77.1-DEV OpenSSL/1.1.1d
* Features: alt-svc AsynchDNS HSTS HTTPS-proxy IPv6 Largefile NTLM NTLM_WB SSL TLS-SRP UnixSockets
* Disabled:
* Host: debian-kernel
* System: Linux debian-kernel 4.19.0-16-amd64 #1 SMP Debian 4.19.181-1 (2021-03-19) x86_64 GNU/Linux
* OS: linux
* Servers: HTTP-IPv6 HTTP-unix FTP-IPv6
* Env:
* Seed: 231622
*****************************************
test 3020...[HTTP with invalid --connect-to syntax]
-------e--- OK (1   out of 1  , remaining: 00:00, took 1.197s, duration: 00:01)
TESTDONE: 1 tests were considered during 1 seconds.
TESTDONE: 1 tests out of 1 reported OK: 100%

@bagder bagder closed this in d8dcb39 Jun 4, 2021
@bagder
Copy link
Member

bagder commented Jun 4, 2021

Thanks! (I edited it a little before pushed)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants