summaryrefslogtreecommitdiff
path: root/serverloop.c
diff options
context:
space:
mode:
authorBen Lindstrom <mouring@eviladmin.org>2001-07-04 04:53:53 +0000
committerBen Lindstrom <mouring@eviladmin.org>2001-07-04 04:53:53 +0000
commitbddd551e1143ba2b7bf0cd453c15b97817bc917d (patch)
tree269daec870fb1889543b6cc73ad3c130da631571 /serverloop.c
parentc5b680018b1fbc58ad2316199693e2805dadf638 (diff)
- markus@cvs.openbsd.org 2001/06/27 02:12:54
[serverloop.c serverloop.h session.c session.h] quick hack to make ssh2 work again.
Diffstat (limited to 'serverloop.c')
-rw-r--r--serverloop.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/serverloop.c b/serverloop.c
index 2eb8603d1..ecc7763a4 100644
--- a/serverloop.c
+++ b/serverloop.c
@@ -35,7 +35,7 @@
35 */ 35 */
36 36
37#include "includes.h" 37#include "includes.h"
38RCSID("$OpenBSD: serverloop.c,v 1.71 2001/06/25 08:25:39 markus Exp $"); 38RCSID("$OpenBSD: serverloop.c,v 1.72 2001/06/27 02:12:52 markus Exp $");
39 39
40#include "xmalloc.h" 40#include "xmalloc.h"
41#include "packet.h" 41#include "packet.h"
@@ -59,6 +59,7 @@ extern ServerOptions options;
59 59
60/* XXX */ 60/* XXX */
61extern Kex *xxx_kex; 61extern Kex *xxx_kex;
62static Authctxt *xxx_authctxt;
62 63
63static Buffer stdin_buffer; /* Buffer for stdin data. */ 64static Buffer stdin_buffer; /* Buffer for stdin data. */
64static Buffer stdout_buffer; /* Buffer for stdout data. */ 65static Buffer stdout_buffer; /* Buffer for stdout data. */
@@ -658,7 +659,7 @@ server_loop(pid_t pid, int fdin_arg, int fdout_arg, int fderr_arg)
658} 659}
659 660
660void 661void
661server_loop2(void) 662server_loop2(Authctxt *authctxt)
662{ 663{
663 fd_set *readset = NULL, *writeset = NULL; 664 fd_set *readset = NULL, *writeset = NULL;
664 int rekeying = 0, max_fd, status; 665 int rekeying = 0, max_fd, status;
@@ -672,6 +673,7 @@ server_loop2(void)
672 connection_out = packet_get_connection_out(); 673 connection_out = packet_get_connection_out();
673 674
674 max_fd = MAX(connection_in, connection_out); 675 max_fd = MAX(connection_in, connection_out);
676 xxx_authctxt = authctxt;
675 677
676 server_init_dispatch(); 678 server_init_dispatch();
677 679
@@ -818,7 +820,7 @@ server_request_session(char *ctype)
818 error("server_request_session: channel_new failed"); 820 error("server_request_session: channel_new failed");
819 return NULL; 821 return NULL;
820 } 822 }
821 if (session_open(c->self) != 1) { 823 if (session_open(xxx_authctxt, c->self) != 1) {
822 debug("session open failed, free channel %d", c->self); 824 debug("session open failed, free channel %d", c->self);
823 channel_free(c); 825 channel_free(c);
824 return NULL; 826 return NULL;