summaryrefslogtreecommitdiffstats
path: root/channels.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2006-03-26 14:10:14 +1100
committerDamien Miller <djm@mindrot.org>2006-03-26 14:10:14 +1100
commit4f7becb44f26b61673b8478fd4aeee262adaf446 (patch)
tree29c6add44136bea0e0a4a1a60f21f884749aa444 /channels.c
parent1d2b6706ba1b2000bd807731e6d8e35691eaf8df (diff)
- deraadt@cvs.openbsd.org 2006/03/20 18:48:34
[channels.c fatal.c kex.c packet.c serverloop.c] spacing
Diffstat (limited to 'channels.c')
-rw-r--r--channels.c22
1 files changed, 8 insertions, 14 deletions
diff --git a/channels.c b/channels.c
index 239da8e9..1ff7152a 100644
--- a/channels.c
+++ b/channels.c
@@ -192,7 +192,6 @@ channel_lookup(int id)
* Register filedescriptors for a channel, used when allocating a channel or
* when the channel consumer/producer is ready, e.g. shell exec'd
*/
-
static void
channel_register_fds(Channel *c, int rfd, int wfd, int efd,
int extusage, int nonblock)
@@ -239,7 +238,6 @@ channel_register_fds(Channel *c, int rfd, int wfd, int efd,
* Allocate a new channel object and set its type and socket. This will cause
* remote_name to be freed.
*/
-
Channel *
channel_new(char *ctype, int type, int rfd, int wfd, int efd,
u_int window, u_int maxpack, int extusage, char *remote_name, int nonblock)
@@ -341,7 +339,6 @@ channel_close_fd(int *fdp)
}
/* Close all channel fd/socket. */
-
static void
channel_close_fds(Channel *c)
{
@@ -356,7 +353,6 @@ channel_close_fds(Channel *c)
}
/* Free the channel and close its fd/socket. */
-
void
channel_free(Channel *c)
{
@@ -403,7 +399,6 @@ channel_free_all(void)
* Closes the sockets/fds of all channels. This is used to close extra file
* descriptors after a fork.
*/
-
void
channel_close_all(void)
{
@@ -417,7 +412,6 @@ channel_close_all(void)
/*
* Stop listening to channels.
*/
-
void
channel_stop_listening(void)
{
@@ -444,7 +438,6 @@ channel_stop_listening(void)
* Returns true if no channel has too much buffered data, and false if one or
* more channel is overfull.
*/
-
int
channel_not_very_much_buffered_data(void)
{
@@ -474,7 +467,6 @@ channel_not_very_much_buffered_data(void)
}
/* Returns true if any channel is still open. */
-
int
channel_still_open(void)
{
@@ -517,7 +509,6 @@ channel_still_open(void)
}
/* Returns the id of an open channel suitable for keepaliving */
-
int
channel_find_open(void)
{
@@ -562,7 +553,6 @@ channel_find_open(void)
* suitable for sending to the client. The message contains crlf pairs for
* newlines.
*/
-
char *
channel_open_message(void)
{
@@ -647,6 +637,7 @@ channel_request_start(int id, char *service, int wantconfirm)
packet_put_cstring(service);
packet_put_char(wantconfirm);
}
+
void
channel_register_confirm(int id, channel_callback_fn *fn, void *ctx)
{
@@ -659,6 +650,7 @@ channel_register_confirm(int id, channel_callback_fn *fn, void *ctx)
c->confirm = fn;
c->confirm_ctx = ctx;
}
+
void
channel_register_cleanup(int id, channel_callback_fn *fn, int do_close)
{
@@ -671,6 +663,7 @@ channel_register_cleanup(int id, channel_callback_fn *fn, int do_close)
c->detach_user = fn;
c->detach_close = do_close;
}
+
void
channel_cancel_cleanup(int id)
{
@@ -683,6 +676,7 @@ channel_cancel_cleanup(int id)
c->detach_user = NULL;
c->detach_close = 0;
}
+
void
channel_register_filter(int id, channel_infilter_fn *ifn,
channel_outfilter_fn *ofn)
@@ -1455,6 +1449,7 @@ channel_handle_rfd(Channel *c, fd_set *readset, fd_set *writeset)
}
return 1;
}
+
static int
channel_handle_wfd(Channel *c, fd_set *readset, fd_set *writeset)
{
@@ -1542,6 +1537,7 @@ channel_handle_wfd(Channel *c, fd_set *readset, fd_set *writeset)
}
return 1;
}
+
static int
channel_handle_efd(Channel *c, fd_set *readset, fd_set *writeset)
{
@@ -1585,6 +1581,7 @@ channel_handle_efd(Channel *c, fd_set *readset, fd_set *writeset)
}
return 1;
}
+
static int
channel_handle_ctl(Channel *c, fd_set *readset, fd_set *writeset)
{
@@ -1612,6 +1609,7 @@ channel_handle_ctl(Channel *c, fd_set *readset, fd_set *writeset)
}
return 1;
}
+
static int
channel_check_window(Channel *c)
{
@@ -1823,7 +1821,6 @@ channel_after_select(fd_set *readset, fd_set *writeset)
/* If there is data to send to the connection, enqueue some of it now. */
-
void
channel_output_poll(void)
{
@@ -1943,7 +1940,6 @@ channel_output_poll(void)
/* -- protocol input */
-
void
channel_input_data(int type, u_int32_t seq, void *ctxt)
{
@@ -2557,7 +2553,6 @@ channel_request_rforward_cancel(const char *host, u_short port)
* listening for the port, and sends back a success reply (or disconnect
* message if there was an error). This never returns if there was an error.
*/
-
void
channel_input_port_forward_request(int is_root, int gateway_ports)
{
@@ -2628,7 +2623,6 @@ channel_clear_permitted_opens(void)
}
-
/* return socket to remote host, port */
static int
connect_to(const char *host, u_short port)