int err = 0;
int sz = sizeof(err);
c->type = SSH_CHANNEL_OPEN;
- if (getsockopt(c->sock, SOL_SOCKET, SO_ERROR, (char *)&err, &sz) < 0) {
+ if (getsockopt(c->sock, SOL_SOCKET, SO_ERROR, (char *)&err, &sz) < 0) {
debug("getsockopt SO_ERROR failed");
} else {
if (err == 0) {
if (remote_fwd) {
host = listen_address;
- ctype = SSH_CHANNEL_RPORT_LISTENER;
+ ctype = SSH_CHANNEL_RPORT_LISTENER;
} else {
host = host_to_connect;
ctype =SSH_CHANNEL_PORT_LISTENER;
error("bind: %.100s", strerror(errno));
else
verbose("bind: %.100s", strerror(errno));
-
+
close(sock);
continue;
}
error("connect %.100s port %s: %.100s", ntop, strport,
strerror(errno));
close(sock);
- continue; /* fail -- try next */
+ continue; /* fail -- try next */
}
break; /* success */
}
freeaddrinfo(aitop);
if (!ai) {
- error("connect %.100s port %d: failed.", host, host_port);
+ error("connect %.100s port %d: failed.", host, host_port);
return -1;
}
/* success */
fatal("gethostname: %.100s", strerror(errno));
#ifdef IPADDR_IN_DISPLAY
- /*
+ /*
* HPUX detects the local hostname in the DISPLAY variable and tries
* to set up a shared memory connection to the server, which it
* incorrectly supposes to be local.
memcpy(&my_addr, he->h_addr_list[0], sizeof(struct in_addr));
/* Set DISPLAY to <ip address>:screen.display */
- snprintf(display, sizeof(display), "%.50s:%d.%d", inet_ntoa(my_addr),
+ snprintf(display, sizeof(display), "%.50s:%d.%d", inet_ntoa(my_addr),
display_number, screen_number);
}
#else /* IPADDR_IN_DISPLAY */
}
c->dettach_user = NULL;
}
-void
+void
channel_register_filter(int id, channel_filter_fn *fn)
{
Channel *c = channel_lookup(id);