1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-07 06:22:47 -05:00

The command-line routines now take a pointer to `cfg' as an

argument, so they don't depend on it being a global any more.

[originally from svn r2555]
This commit is contained in:
Simon Tatham
2003-01-12 14:17:03 +00:00
parent fee1624c69
commit 5738dc219b
6 changed files with 47 additions and 45 deletions

View File

@ -1722,7 +1722,7 @@ static int psftp_connect(char *userhost, char *user, int portnumber)
/*
* Enact command-line overrides.
*/
cmdline_run_saved();
cmdline_run_saved(&cfg);
/*
* Trim leading whitespace off the hostname if it's there.
@ -1883,7 +1883,7 @@ int main(int argc, char *argv[])
userhost = dupstr(argv[i]);
continue;
}
ret = cmdline_process_param(argv[i], i+1<argc?argv[i+1]:NULL, 1);
ret = cmdline_process_param(argv[i], i+1<argc?argv[i+1]:NULL, 1, &cfg);
if (ret == -2) {
cmdline_error("option \"%s\" requires an argument", argv[i]);
} else if (ret == 2) {