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

Diff for /src/usr.bin/ssh/readpass.c between version 1.35.2.1 and 1.36

version 1.35.2.1, 2006/09/30 04:06:51 version 1.36, 2006/03/19 18:51:18
Line 1 
Line 1 
 /* $OpenBSD$ */  
 /*  /*
  * Copyright (c) 2001 Markus Friedl.  All rights reserved.   * Copyright (c) 2001 Markus Friedl.  All rights reserved.
  *   *
Line 23 
Line 22 
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.   * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */   */
   
   #include "includes.h"
   
 #include <sys/types.h>  #include <sys/types.h>
 #include <sys/wait.h>  #include <sys/wait.h>
   
 #include <errno.h>  
 #include <fcntl.h>  
 #include <paths.h>  #include <paths.h>
 #include <readpassphrase.h>  #include <readpassphrase.h>
 #include <stdarg.h>  
 #include <stdio.h>  
 #include <stdlib.h>  
 #include <string.h>  
 #include <unistd.h>  
   
 #include "xmalloc.h"  #include "xmalloc.h"
 #include "misc.h"  #include "misc.h"
 #include "pathnames.h"  #include "pathnames.h"
 #include "log.h"  #include "log.h"
 #include "ssh.h"  #include "ssh.h"
 #include "uidswap.h"  
   
 static char *  static char *
 ssh_askpass(char *askpass, const char *msg)  ssh_askpass(char *askpass, const char *msg)
Line 65 
Line 58 
                 return NULL;                  return NULL;
         }          }
         if (pid == 0) {          if (pid == 0) {
                 permanently_drop_suid(getuid());                  seteuid(getuid());
                   setuid(getuid());
                 close(p[0]);                  close(p[0]);
                 if (dup2(p[1], STDOUT_FILENO) < 0)                  if (dup2(p[1], STDOUT_FILENO) < 0)
                         fatal("ssh_askpass: dup2: %s", strerror(errno));                          fatal("ssh_askpass: dup2: %s", strerror(errno));

Legend:
Removed from v.1.35.2.1  
changed lines
  Added in v.1.36