Replace ChanType.sepfds with Channel.bidir_fd

This handles the case where a svrchansess has separate FDs
for nopty, but a single FD for pty mode.

The use of sepfds was also previously incorrect for X11 and
agent forwarding
This commit is contained in:
Matt Johnston
2021-10-11 15:42:14 +08:00
parent 8e6f73e879
commit f17400e738
9 changed files with 13 additions and 15 deletions

View File

@@ -59,7 +59,6 @@ static int newtcpdirect(struct Channel * channel);
#if DROPBEAR_SVR_REMOTETCPFWD
static const struct ChanType svr_chan_tcpremote = {
1, /* sepfds */
"forwarded-tcpip",
tcp_prio_inithandler,
NULL,
@@ -241,7 +240,6 @@ out:
#if DROPBEAR_SVR_LOCALTCPFWD
const struct ChanType svr_chan_tcpdirect = {
1, /* sepfds */
"direct-tcpip",
newtcpdirect, /* init */
NULL, /* checkclose */