[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.40 and 1.41

version 1.40, 2000/10/15 14:14:01 version 1.41, 2000/10/18 18:42:00
Line 89 
Line 89 
 void    session_proctitle(Session *s);  void    session_proctitle(Session *s);
 void    do_exec_pty(Session *s, const char *command, struct passwd * pw);  void    do_exec_pty(Session *s, const char *command, struct passwd * pw);
 void    do_exec_no_pty(Session *s, const char *command, struct passwd * pw);  void    do_exec_no_pty(Session *s, const char *command, struct passwd * pw);
 void    do_login(Session *s);  void    do_login(Session *s, const char *command);
   
 void  void
 do_child(const char *command, struct passwd * pw, const char *term,  do_child(const char *command, struct passwd * pw, const char *term,
Line 572 
Line 572 
                 close(ttyfd);                  close(ttyfd);
   
                 /* record login, etc. similar to login(1) */                  /* record login, etc. similar to login(1) */
                 if (command == NULL && !options.use_login)                  if (!(options.use_login && command == NULL))
                         do_login(s);                          do_login(s, command);
   
                 /* Do common processing for the child, such as execing the command. */                  /* Do common processing for the child, such as execing the command. */
                 do_child(command, pw, s->term, s->display, s->auth_proto,                  do_child(command, pw, s->term, s->display, s->auth_proto,
Line 625 
Line 625 
   
 /* administrative, login(1)-like work */  /* administrative, login(1)-like work */
 void  void
 do_login(Session *s)  do_login(Session *s, const char *command)
 {  {
         FILE *f;          FILE *f;
         char *time_string;          char *time_string;
Line 661 
Line 661 
         record_login(pid, s->tty, pw->pw_name, pw->pw_uid,          record_login(pid, s->tty, pw->pw_name, pw->pw_uid,
             get_remote_name_or_ip(), (struct sockaddr *)&from);              get_remote_name_or_ip(), (struct sockaddr *)&from);
   
         /* Done if .hushlogin exists. */          /* Done if .hushlogin exists or a command given. */
           if (command != NULL)
                   return;
         snprintf(buf, sizeof(buf), "%.200s/.hushlogin", pw->pw_dir);          snprintf(buf, sizeof(buf), "%.200s/.hushlogin", pw->pw_dir);
 #ifdef HAVE_LOGIN_CAP  #ifdef HAVE_LOGIN_CAP
         if (login_getcapbool(lc, "hushlogin", 0) || stat(buf, &st) >= 0)          if (login_getcapbool(lc, "hushlogin", 0) || stat(buf, &st) >= 0)

Legend:
Removed from v.1.40  
changed lines
  Added in v.1.41