mirror of
https://github.com/mirror/wget.git
synced 2025-01-07 19:00:30 +08:00
[svn] Re-alphabetize the command list. Have run_command correctly interpret
the new return value of parse_line.
This commit is contained in:
parent
0b49b79bb7
commit
79c4490734
@ -1,3 +1,9 @@
|
|||||||
|
2005-05-08 Hrvoje Niksic <hniksic@xemacs.org>
|
||||||
|
|
||||||
|
* init.c (run_command): Correctly interpret the return value of
|
||||||
|
parse_line.
|
||||||
|
(commands): Re-alphabetize.
|
||||||
|
|
||||||
2005-05-08 Hrvoje Niksic <hniksic@xemacs.org>
|
2005-05-08 Hrvoje Niksic <hniksic@xemacs.org>
|
||||||
|
|
||||||
* netrc.c (parse_netrc): Explicitly check for assignment != NULL
|
* netrc.c (parse_netrc): Explicitly check for assignment != NULL
|
||||||
|
11
src/init.c
11
src/init.c
@ -159,8 +159,8 @@ static struct {
|
|||||||
{ "forcehtml", &opt.force_html, cmd_boolean },
|
{ "forcehtml", &opt.force_html, cmd_boolean },
|
||||||
{ "ftppasswd", &opt.ftp_passwd, cmd_string }, /* deprecated */
|
{ "ftppasswd", &opt.ftp_passwd, cmd_string }, /* deprecated */
|
||||||
{ "ftppassword", &opt.ftp_passwd, cmd_string },
|
{ "ftppassword", &opt.ftp_passwd, cmd_string },
|
||||||
{ "ftpuser", &opt.ftp_user, cmd_string },
|
|
||||||
{ "ftpproxy", &opt.ftp_proxy, cmd_string },
|
{ "ftpproxy", &opt.ftp_proxy, cmd_string },
|
||||||
|
{ "ftpuser", &opt.ftp_user, cmd_string },
|
||||||
{ "glob", &opt.ftp_glob, cmd_boolean },
|
{ "glob", &opt.ftp_glob, cmd_boolean },
|
||||||
{ "header", &opt.user_headers, cmd_spec_header },
|
{ "header", &opt.user_headers, cmd_spec_header },
|
||||||
{ "htmlextension", &opt.html_extension, cmd_boolean },
|
{ "htmlextension", &opt.html_extension, cmd_boolean },
|
||||||
@ -649,16 +649,15 @@ run_command (const char *opt)
|
|||||||
{
|
{
|
||||||
char *com, *val;
|
char *com, *val;
|
||||||
int comind;
|
int comind;
|
||||||
int status = parse_line (opt, &com, &val, &comind);
|
switch (parse_line (opt, &com, &val, &comind))
|
||||||
if (status == 1)
|
|
||||||
{
|
{
|
||||||
|
case line_ok:
|
||||||
if (!setval_internal (comind, com, val))
|
if (!setval_internal (comind, com, val))
|
||||||
exit (2);
|
exit (2);
|
||||||
xfree (com);
|
xfree (com);
|
||||||
xfree (val);
|
xfree (val);
|
||||||
}
|
break;
|
||||||
else if (status == 0)
|
default:
|
||||||
{
|
|
||||||
fprintf (stderr, _("%s: Invalid --execute command `%s'\n"),
|
fprintf (stderr, _("%s: Invalid --execute command `%s'\n"),
|
||||||
exec_name, opt);
|
exec_name, opt);
|
||||||
exit (2);
|
exit (2);
|
||||||
|
Loading…
Reference in New Issue
Block a user