diff options
Diffstat (limited to 'channels.c')
-rw-r--r-- | channels.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/channels.c b/channels.c index 82a2db05e..d343ac89e 100644 --- a/channels.c +++ b/channels.c | |||
@@ -40,7 +40,7 @@ | |||
40 | */ | 40 | */ |
41 | 41 | ||
42 | #include "includes.h" | 42 | #include "includes.h" |
43 | RCSID("$OpenBSD: channels.c,v 1.85 2001/01/29 19:42:35 markus Exp $"); | 43 | RCSID("$OpenBSD: channels.c,v 1.88 2001/02/01 21:58:08 markus Exp $"); |
44 | 44 | ||
45 | #include <openssl/rsa.h> | 45 | #include <openssl/rsa.h> |
46 | #include <openssl/dsa.h> | 46 | #include <openssl/dsa.h> |
@@ -600,7 +600,7 @@ channel_post_port_listener(Channel *c, fd_set * readset, fd_set * writeset) | |||
600 | struct sockaddr addr; | 600 | struct sockaddr addr; |
601 | int newsock, newch; | 601 | int newsock, newch; |
602 | socklen_t addrlen; | 602 | socklen_t addrlen; |
603 | char buf[1024], *remote_hostname, *rtype; | 603 | char buf[1024], *remote_ipaddr, *rtype; |
604 | int remote_port; | 604 | int remote_port; |
605 | 605 | ||
606 | rtype = (c->type == SSH_CHANNEL_RPORT_LISTENER) ? | 606 | rtype = (c->type == SSH_CHANNEL_RPORT_LISTENER) ? |
@@ -616,13 +616,13 @@ channel_post_port_listener(Channel *c, fd_set * readset, fd_set * writeset) | |||
616 | error("accept: %.100s", strerror(errno)); | 616 | error("accept: %.100s", strerror(errno)); |
617 | return; | 617 | return; |
618 | } | 618 | } |
619 | remote_hostname = get_remote_hostname(newsock); | 619 | remote_ipaddr = get_peer_ipaddr(newsock); |
620 | remote_port = get_peer_port(newsock); | 620 | remote_port = get_peer_port(newsock); |
621 | snprintf(buf, sizeof buf, | 621 | snprintf(buf, sizeof buf, |
622 | "listen port %d for %.100s port %d, " | 622 | "listen port %d for %.100s port %d, " |
623 | "connect from %.200s port %d", | 623 | "connect from %.200s port %d", |
624 | c->listening_port, c->path, c->host_port, | 624 | c->listening_port, c->path, c->host_port, |
625 | remote_hostname, remote_port); | 625 | remote_ipaddr, remote_port); |
626 | 626 | ||
627 | newch = channel_new(rtype, | 627 | newch = channel_new(rtype, |
628 | SSH_CHANNEL_OPENING, newsock, newsock, -1, | 628 | SSH_CHANNEL_OPENING, newsock, newsock, -1, |
@@ -644,7 +644,7 @@ channel_post_port_listener(Channel *c, fd_set * readset, fd_set * writeset) | |||
644 | packet_put_int(c->host_port); | 644 | packet_put_int(c->host_port); |
645 | } | 645 | } |
646 | /* originator host and port */ | 646 | /* originator host and port */ |
647 | packet_put_cstring(remote_hostname); | 647 | packet_put_cstring(remote_ipaddr); |
648 | packet_put_int(remote_port); | 648 | packet_put_int(remote_port); |
649 | packet_send(); | 649 | packet_send(); |
650 | } else { | 650 | } else { |
@@ -657,7 +657,7 @@ channel_post_port_listener(Channel *c, fd_set * readset, fd_set * writeset) | |||
657 | } | 657 | } |
658 | packet_send(); | 658 | packet_send(); |
659 | } | 659 | } |
660 | xfree(remote_hostname); | 660 | xfree(remote_ipaddr); |
661 | } | 661 | } |
662 | } | 662 | } |
663 | 663 | ||