diff options
author | Damien Miller <djm@mindrot.org> | 2001-12-21 14:45:46 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2001-12-21 14:45:46 +1100 |
commit | 9f0f5c64bc4b6144e3fed6a7f538f7c21819a492 (patch) | |
tree | f79317ab211f59181a61b526f566e9c8cfe70c73 /channels.c | |
parent | 89681214ca2f50a1b1ed6164c3afe1ce14995ffc (diff) |
- deraadt@cvs.openbsd.org 2001/12/19 07:18:56
[auth1.c auth2.c auth2-chall.c auth-bsdauth.c auth.c authfile.c auth.h]
[auth-krb4.c auth-rhosts.c auth-skey.c bufaux.c canohost.c channels.c]
[cipher.c clientloop.c compat.c compress.c deattack.c key.c log.c mac.c]
[match.c misc.c nchan.c packet.c readconf.c rijndael.c rijndael.h scard.c]
[servconf.c servconf.h serverloop.c session.c sftp.c sftp-client.c]
[sftp-glob.c sftp-int.c sftp-server.c ssh-add.c ssh-agent.c ssh.c]
[sshconnect1.c sshconnect2.c sshconnect.c sshd.8 sshd.c sshd_config]
[ssh-keygen.c sshlogin.c sshpty.c sshtty.c ttymodes.c uidswap.c]
basic KNF done while i was looking for something else
Diffstat (limited to 'channels.c')
-rw-r--r-- | channels.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/channels.c b/channels.c index 97a865f56..63eb5bcff 100644 --- a/channels.c +++ b/channels.c | |||
@@ -39,7 +39,7 @@ | |||
39 | */ | 39 | */ |
40 | 40 | ||
41 | #include "includes.h" | 41 | #include "includes.h" |
42 | RCSID("$OpenBSD: channels.c,v 1.147 2001/12/08 17:49:28 stevesk Exp $"); | 42 | RCSID("$OpenBSD: channels.c,v 1.148 2001/12/19 07:18:56 deraadt Exp $"); |
43 | 43 | ||
44 | #include "ssh.h" | 44 | #include "ssh.h" |
45 | #include "ssh1.h" | 45 | #include "ssh1.h" |
@@ -794,7 +794,7 @@ x11_open_helper(Buffer *b) | |||
794 | data_len = ucp[8] + 256 * ucp[9]; | 794 | data_len = ucp[8] + 256 * ucp[9]; |
795 | } else { | 795 | } else { |
796 | debug("Initial X11 packet contains bad byte order byte: 0x%x", | 796 | debug("Initial X11 packet contains bad byte order byte: 0x%x", |
797 | ucp[0]); | 797 | ucp[0]); |
798 | return -1; | 798 | return -1; |
799 | } | 799 | } |
800 | 800 | ||
@@ -884,7 +884,7 @@ channel_decode_socks4(Channel *c, fd_set * readset, fd_set * writeset) | |||
884 | { | 884 | { |
885 | u_char *p, *host; | 885 | u_char *p, *host; |
886 | int len, have, i, found; | 886 | int len, have, i, found; |
887 | char username[256]; | 887 | char username[256]; |
888 | struct { | 888 | struct { |
889 | u_int8_t version; | 889 | u_int8_t version; |
890 | u_int8_t command; | 890 | u_int8_t command; |
@@ -931,7 +931,7 @@ channel_decode_socks4(Channel *c, fd_set * readset, fd_set * writeset) | |||
931 | host = inet_ntoa(s4_req.dest_addr); | 931 | host = inet_ntoa(s4_req.dest_addr); |
932 | strlcpy(c->path, host, sizeof(c->path)); | 932 | strlcpy(c->path, host, sizeof(c->path)); |
933 | c->host_port = ntohs(s4_req.dest_port); | 933 | c->host_port = ntohs(s4_req.dest_port); |
934 | 934 | ||
935 | debug("channel %d: dynamic request: socks4 host %s port %u command %u", | 935 | debug("channel %d: dynamic request: socks4 host %s port %u command %u", |
936 | c->self, host, c->host_port, s4_req.command); | 936 | c->self, host, c->host_port, s4_req.command); |
937 | 937 | ||
@@ -1373,7 +1373,7 @@ channel_handle_efd(Channel *c, fd_set * readset, fd_set * writeset) | |||
1373 | FD_ISSET(c->efd, readset)) { | 1373 | FD_ISSET(c->efd, readset)) { |
1374 | len = read(c->efd, buf, sizeof(buf)); | 1374 | len = read(c->efd, buf, sizeof(buf)); |
1375 | debug2("channel %d: read %d from efd %d", | 1375 | debug2("channel %d: read %d from efd %d", |
1376 | c->self, len, c->efd); | 1376 | c->self, len, c->efd); |
1377 | if (len < 0 && (errno == EINTR || errno == EAGAIN)) | 1377 | if (len < 0 && (errno == EINTR || errno == EAGAIN)) |
1378 | return 1; | 1378 | return 1; |
1379 | if (len <= 0) { | 1379 | if (len <= 0) { |
@@ -1509,7 +1509,7 @@ static void | |||
1509 | channel_handler_init(void) | 1509 | channel_handler_init(void) |
1510 | { | 1510 | { |
1511 | int i; | 1511 | int i; |
1512 | for(i = 0; i < SSH_CHANNEL_MAX_TYPE; i++) { | 1512 | for (i = 0; i < SSH_CHANNEL_MAX_TYPE; i++) { |
1513 | channel_pre[i] = NULL; | 1513 | channel_pre[i] = NULL; |
1514 | channel_post[i] = NULL; | 1514 | channel_post[i] = NULL; |
1515 | } | 1515 | } |
@@ -2414,8 +2414,8 @@ x11_create_display_inet(int x11_display_offset, int gateway_ports) | |||
2414 | int gaierr, n, num_socks = 0, socks[NUM_SOCKS]; | 2414 | int gaierr, n, num_socks = 0, socks[NUM_SOCKS]; |
2415 | 2415 | ||
2416 | for (display_number = x11_display_offset; | 2416 | for (display_number = x11_display_offset; |
2417 | display_number < MAX_DISPLAYS; | 2417 | display_number < MAX_DISPLAYS; |
2418 | display_number++) { | 2418 | display_number++) { |
2419 | port = 6000 + display_number; | 2419 | port = 6000 + display_number; |
2420 | memset(&hints, 0, sizeof(hints)); | 2420 | memset(&hints, 0, sizeof(hints)); |
2421 | hints.ai_family = IPv4or6; | 2421 | hints.ai_family = IPv4or6; |
@@ -2541,7 +2541,7 @@ x11_connect_display(void) | |||
2541 | /* Connect to the unix domain socket. */ | 2541 | /* Connect to the unix domain socket. */ |
2542 | if (sscanf(strrchr(display, ':') + 1, "%d", &display_number) != 1) { | 2542 | if (sscanf(strrchr(display, ':') + 1, "%d", &display_number) != 1) { |
2543 | error("Could not parse display number from DISPLAY: %.100s", | 2543 | error("Could not parse display number from DISPLAY: %.100s", |
2544 | display); | 2544 | display); |
2545 | return -1; | 2545 | return -1; |
2546 | } | 2546 | } |
2547 | /* Create a socket. */ | 2547 | /* Create a socket. */ |
@@ -2566,7 +2566,7 @@ x11_connect_display(void) | |||
2566 | /* buf now contains the host name. But first we parse the display number. */ | 2566 | /* buf now contains the host name. But first we parse the display number. */ |
2567 | if (sscanf(cp + 1, "%d", &display_number) != 1) { | 2567 | if (sscanf(cp + 1, "%d", &display_number) != 1) { |
2568 | error("Could not parse display number from DISPLAY: %.100s", | 2568 | error("Could not parse display number from DISPLAY: %.100s", |
2569 | display); | 2569 | display); |
2570 | return -1; | 2570 | return -1; |
2571 | } | 2571 | } |
2572 | 2572 | ||