]> andersk Git - openssh.git/commitdiff
- markus@cvs.openbsd.org 2002/03/19 15:31:47
authormouring <mouring>
Fri, 22 Mar 2002 03:08:30 +0000 (03:08 +0000)
committermouring <mouring>
Fri, 22 Mar 2002 03:08:30 +0000 (03:08 +0000)
     [auth.c]
     check for NULL; from provos@

ChangeLog
auth.c

index c137c084d10b9dc795b1d08a593f3f2dddcf0b56..1bc713dec64a3a6b230bd581d165d9447bf3511f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -97,6 +97,9 @@
    - markus@cvs.openbsd.org 2002/03/19 14:27:39
      [auth.c auth1.c auth2.c]
      make getpwnamallow() allways call pwcopy()
+   - markus@cvs.openbsd.org 2002/03/19 15:31:47
+     [auth.c]
+     check for NULL; from provos@
 
 20020317
  - (tim) [configure.ac] Assume path given with --with-pid-dir=PATH is wanted,
diff --git a/auth.c b/auth.c
index f368faf21bd81049b411a26e3569361bb2852e3e..a9f981d18e1bfd7a39b0a357a8e023acbdc1e9c6 100644 (file)
--- a/auth.c
+++ b/auth.c
@@ -23,7 +23,7 @@
  */
 
 #include "includes.h"
-RCSID("$OpenBSD: auth.c,v 1.40 2002/03/19 14:27:39 markus Exp $");
+RCSID("$OpenBSD: auth.c,v 1.41 2002/03/19 15:31:47 markus Exp $");
 
 #ifdef HAVE_LOGIN_H
 #include <login.h>
@@ -470,5 +470,7 @@ getpwnamallow(const char *user)
                auth_close(as);
 #endif
 #endif
-       return (pwcopy(pw));
+       if (pw != NULL)
+               return (pwcopy(pw));
+       return (NULL);
 }
This page took 0.045366 seconds and 5 git commands to generate.