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

Diff for /src/usr.bin/ssh/monitor.c between version 1.60 and 1.61

version 1.60, 2004/06/22 05:05:45 version 1.61, 2004/07/17 05:31:41
Line 73 
Line 73 
 extern Buffer input, output;  extern Buffer input, output;
 extern Buffer auth_debug;  extern Buffer auth_debug;
 extern int auth_debug_init;  extern int auth_debug_init;
   extern Buffer loginmsg;
   
 /* State exported from the child */  /* State exported from the child */
   
Line 1051 
Line 1052 
   
         buffer_put_int(m, 1);          buffer_put_int(m, 1);
         buffer_put_cstring(m, s->tty);          buffer_put_cstring(m, s->tty);
         mm_request_send(sock, MONITOR_ANS_PTY, m);  
   
         mm_send_fd(sock, s->ptyfd);  
         mm_send_fd(sock, s->ttyfd);  
   
         /* We need to trick ttyslot */          /* We need to trick ttyslot */
         if (dup2(s->ttyfd, 0) == -1)          if (dup2(s->ttyfd, 0) == -1)
                 fatal("%s: dup2", __func__);                  fatal("%s: dup2", __func__);
Line 1064 
Line 1061 
   
         /* Now we can close the file descriptor again */          /* Now we can close the file descriptor again */
         close(0);          close(0);
   
           /* send messages generated by record_login */
           buffer_put_string(m, buffer_ptr(&loginmsg), buffer_len(&loginmsg));
           buffer_clear(&loginmsg);
   
           mm_request_send(sock, MONITOR_ANS_PTY, m);
   
           mm_send_fd(sock, s->ptyfd);
           mm_send_fd(sock, s->ttyfd);
   
         /* make sure nothing uses fd 0 */          /* make sure nothing uses fd 0 */
         if ((fd0 = open(_PATH_DEVNULL, O_RDONLY)) < 0)          if ((fd0 = open(_PATH_DEVNULL, O_RDONLY)) < 0)

Legend:
Removed from v.1.60  
changed lines
  Added in v.1.61