1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-01 11:32:48 -05:00

proxy.c now no longer refers to `cfg'. Instead, each of the three

proxy-indirection network functions (name_lookup, new_connection,
new_listener) takes a `const Config *' as an argument, and extracts
enough information from it before returning to handle that
particular network operation in accordance with the proxy settings
it specifies. This involved {win,ux}net.c due to a `const'
repercussion.

[originally from svn r2567]
This commit is contained in:
Simon Tatham
2003-01-12 15:26:10 +00:00
parent 2d469ba497
commit 952857fca3
12 changed files with 122 additions and 95 deletions

View File

@ -227,7 +227,7 @@ int x11_get_screen_number(char *display)
* also, fills the SocketsStructure
*/
char *x11_init(Socket * s, char *display, void *c, void *auth,
const char *peeraddr, int peerport)
const char *peeraddr, int peerport, const Config *cfg)
{
static const struct plug_function_table fn_table = {
x11_closing,
@ -269,7 +269,7 @@ char *x11_init(Socket * s, char *display, void *c, void *auth,
/*
* Try to find host.
*/
addr = name_lookup(host, port, &dummy_realhost);
addr = name_lookup(host, port, &dummy_realhost, cfg);
if ((err = sk_addr_error(addr)) != NULL)
return err;
@ -285,7 +285,8 @@ char *x11_init(Socket * s, char *display, void *c, void *auth,
pr->throttled = pr->throttle_override = 0;
pr->c = c;
pr->s = *s = new_connection(addr, dummy_realhost, port, 0, 1, 0, (Plug) pr);
pr->s = *s = new_connection(addr, dummy_realhost, port,
0, 1, 0, (Plug) pr, cfg);
if ((err = sk_socket_error(*s)) != NULL) {
sfree(pr);
return err;