1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-06-30 19:12:48 -05:00

Pass an Interactor to new_connection().

Thanks to the previous commit, this new parameter can replace two of
the existing ones: instead of passing a LogPolicy and a Seat, we now
pass just an Interactor, from which any proxy implementation can
extract the LogPolicy and the Seat anyway if they need it.
This commit is contained in:
Simon Tatham
2021-10-30 17:36:52 +01:00
parent aac5e096fa
commit 89a390bdeb
14 changed files with 43 additions and 49 deletions

View File

@ -1159,7 +1159,7 @@ char *portfwdmgr_connect(PortFwdManager *mgr, Channel **chan_ret,
pf->s = new_connection(addr, dummy_realhost, port,
false, true, false, false, &pf->plug, mgr->conf,
NULL, NULL);
NULL);
sfree(dummy_realhost);
if ((err = sk_socket_error(pf->s)) != NULL) {
char *err_ret = dupstr(err);

View File

@ -826,8 +826,7 @@ static char *connect_to_host(
ssh->s = new_connection(addr, *realhost, port,
false, true, nodelay, keepalive,
&ssh->plug, ssh->conf,
log_get_policy(ssh->logctx), &ssh->seat);
&ssh->plug, ssh->conf, &ssh->interactor);
if ((err = sk_socket_error(ssh->s)) != NULL) {
ssh->s = NULL;
seat_notify_remote_exit(ssh->seat);

View File

@ -563,7 +563,7 @@ static size_t x11_send(
xconn->s = new_connection(sk_addr_dup(xconn->disp->addr),
xconn->disp->realhost, xconn->disp->port,
false, true, false, false, &xconn->plug,
sshfwd_get_conf(xconn->c), NULL, NULL);
sshfwd_get_conf(xconn->c), NULL);
if ((err = sk_socket_error(xconn->s)) != NULL) {
char *err_message = dupprintf("unable to connect to"
" forwarded X server: %s", err);