[BACK]Return to session.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / ssh

Diff for /src/usr.bin/ssh/session.c between version 1.239 and 1.240

version 1.239, 2008/06/14 18:33:43 version 1.240, 2008/06/15 20:06:26
Line 90 
Line 90 
 /* func */  /* func */
   
 Session *session_new(void);  Session *session_new(void);
 void    session_set_fds(Session *, int, int, int);  void    session_set_fds(Session *, int, int, int, int);
 void    session_pty_cleanup(Session *);  void    session_pty_cleanup(Session *);
 void    session_proctitle(Session *);  void    session_proctitle(Session *);
 int     session_setup_x11fwd(Session *);  int     session_setup_x11fwd(Session *);
Line 557 
Line 557 
                         close(perr[0]);                          close(perr[0]);
                         perr[0] = -1;                          perr[0] = -1;
                 }                  }
                 session_set_fds(s, pin[1], pout[0], perr[0]);                  session_set_fds(s, pin[1], pout[0], perr[0], 0);
         } else {          } else {
                 /* Enter the interactive session. */                  /* Enter the interactive session. */
                 server_loop(pid, pin[1], pout[0], perr[0]);                  server_loop(pid, pin[1], pout[0], perr[0]);
Line 574 
Line 574 
          */           */
         if (compat20) {          if (compat20) {
                 session_set_fds(s, inout[1], inout[1],                  session_set_fds(s, inout[1], inout[1],
                     s->is_subsystem ? -1 : err[1]);                      s->is_subsystem ? -1 : err[1], 0);
                 if (s->is_subsystem)                  if (s->is_subsystem)
                         close(err[1]);                          close(err[1]);
         } else {          } else {
Line 681 
Line 681 
         s->ptymaster = ptymaster;          s->ptymaster = ptymaster;
         packet_set_interactive(1);          packet_set_interactive(1);
         if (compat20) {          if (compat20) {
                 session_set_fds(s, ptyfd, fdout, -1);                  session_set_fds(s, ptyfd, fdout, -1, 1);
         } else {          } else {
                 server_loop(pid, ptyfd, fdout, -1);                  server_loop(pid, ptyfd, fdout, -1);
                 /* server_loop _has_ closed ptyfd and fdout. */                  /* server_loop _has_ closed ptyfd and fdout. */
Line 1883 
Line 1883 
 }  }
   
 void  void
 session_set_fds(Session *s, int fdin, int fdout, int fderr)  session_set_fds(Session *s, int fdin, int fdout, int fderr, int isatty)
 {  {
         if (!compat20)          if (!compat20)
                 fatal("session_set_fds: called for proto != 2.0");                  fatal("session_set_fds: called for proto != 2.0");
Line 1896 
Line 1896 
         channel_set_fds(s->chanid,          channel_set_fds(s->chanid,
             fdout, fdin, fderr,              fdout, fdin, fderr,
             fderr == -1 ? CHAN_EXTENDED_IGNORE : CHAN_EXTENDED_READ,              fderr == -1 ? CHAN_EXTENDED_IGNORE : CHAN_EXTENDED_READ,
             1,              1, isatty, CHAN_SES_WINDOW_DEFAULT);
             CHAN_SES_WINDOW_DEFAULT);  
 }  }
   
 /*  /*

Legend:
Removed from v.1.239  
changed lines
  Added in v.1.240