Stephen Kick's --interface was added
This commit is contained in:
parent
c9c7fcf411
commit
7eafb0f325
@ -243,6 +243,7 @@ static void help(void)
|
|||||||
" -H/--header <line> Custom header to pass to server. (H)\n"
|
" -H/--header <line> Custom header to pass to server. (H)\n"
|
||||||
" -i/--include Include the HTTP-header in the output (H)\n"
|
" -i/--include Include the HTTP-header in the output (H)\n"
|
||||||
" -I/--head Fetch document info only (HTTP HEAD/FTP SIZE)\n"
|
" -I/--head Fetch document info only (HTTP HEAD/FTP SIZE)\n"
|
||||||
|
" --interface <interface> Specify the interface to be used\n"
|
||||||
" -K/--config Specify which config file to read\n"
|
" -K/--config Specify which config file to read\n"
|
||||||
" -l/--list-only List only names of an FTP directory (F)\n"
|
" -l/--list-only List only names of an FTP directory (F)\n"
|
||||||
" -L/--location Follow Location: hints (H)\n"
|
" -L/--location Follow Location: hints (H)\n"
|
||||||
@ -299,6 +300,7 @@ struct Configurable {
|
|||||||
char *headerfile;
|
char *headerfile;
|
||||||
char remotefile;
|
char remotefile;
|
||||||
char *ftpport;
|
char *ftpport;
|
||||||
|
char *interface;
|
||||||
unsigned short porttouse;
|
unsigned short porttouse;
|
||||||
char *range;
|
char *range;
|
||||||
int low_speed_limit;
|
int low_speed_limit;
|
||||||
@ -440,6 +442,7 @@ static int getparameter(char *flag, /* f or -long-flag */
|
|||||||
struct LongShort aliases[]= {
|
struct LongShort aliases[]= {
|
||||||
{"9", "crlf", FALSE},
|
{"9", "crlf", FALSE},
|
||||||
{"8", "stderr", TRUE},
|
{"8", "stderr", TRUE},
|
||||||
|
{"7", "interface", TRUE},
|
||||||
|
|
||||||
{"2", "sslv2", FALSE},
|
{"2", "sslv2", FALSE},
|
||||||
{"3", "sslv3", FALSE},
|
{"3", "sslv3", FALSE},
|
||||||
@ -609,6 +612,9 @@ static int getparameter(char *flag, /* f or -long-flag */
|
|||||||
else
|
else
|
||||||
config->errors = stdout;
|
config->errors = stdout;
|
||||||
break;
|
break;
|
||||||
|
case '7': /* there is no short letter for this */
|
||||||
|
/* interface */
|
||||||
|
GetStr(&config->interface, nextarg);
|
||||||
case '#': /* added 19990617 larsa */
|
case '#': /* added 19990617 larsa */
|
||||||
config->progressmode ^= CURL_PROGRESS_BAR;
|
config->progressmode ^= CURL_PROGRESS_BAR;
|
||||||
break;
|
break;
|
||||||
@ -1495,6 +1501,7 @@ int main(int argc, char *argv[])
|
|||||||
curl_easy_setopt(curl, CURLOPT_STDERR, config.errors);
|
curl_easy_setopt(curl, CURLOPT_STDERR, config.errors);
|
||||||
curl_easy_setopt(curl, CURLOPT_WRITEINFO, config.writeout);
|
curl_easy_setopt(curl, CURLOPT_WRITEINFO, config.writeout);
|
||||||
curl_easy_setopt(curl, CURLOPT_HTTPPROXYTUNNEL, config.proxytunnel);
|
curl_easy_setopt(curl, CURLOPT_HTTPPROXYTUNNEL, config.proxytunnel);
|
||||||
|
curl_easy_setopt(curl, CURLOPT_INTERFACE, config.interface);
|
||||||
|
|
||||||
if((config.progressmode == CURL_PROGRESS_BAR) &&
|
if((config.progressmode == CURL_PROGRESS_BAR) &&
|
||||||
!(config.conf&(CONF_NOPROGRESS|CONF_MUTE))) {
|
!(config.conf&(CONF_NOPROGRESS|CONF_MUTE))) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user