Re: CURLOPT_LOCALPORT option broken ?!
Date: Sat, 21 Feb 2009 02:35:12 +0100
I hope you took the second patch.
I tested this using the curl cli, and would be glad if you could too.
curl --interface 10.0.110.131 --local-port 60027-60028
Would match your query.
As I do not have 10.20.4.19 here, here is a slightly different output
when asking for curl.haxx.se.
/opt/curl/bin/curl --verbose --interface 192.168.53.20 --local-port
41022-41023 http://curl.haxx.se > /dev/null
* About to connect() to curl.haxx.se port 80 (#0)
* Trying 18.104.22.168... Domain 192.168.53.20 is ip 192.168.53.20
* Local port: 41022
* Connected to curl.haxx.se (22.214.171.124) port 80 (#0)
If I take your output correct, "10.0.110.131" was not 'resolved' to an
ip address correctly.
> CURL: Trying 10.20.4.19... CURL: Domain 10.0.110.131 is ip
that line should look like:
"CURL: Trying 10.20.4.19... CURL: Domain 10.0.110.131 is ip 10.0.110.131"
Maybe Daniel can tell help me out on Curl_resolv and Curl_resolv_unlock?
Curl_resolv returns, h is not NULL, but the result is empty string?
Which resolver do you use?
Additionally, please try
curl --interface eth0 --local-port 60027-60028
and replace eth0 by your interface
as well as
curl --interface myhostname --local-port 60027-60028
and replace the hostname with your hostname.
and include the output with your mail.
Received on 2009-02-21