From 2aecee364f2b1fa8b38c4d29600f05f33075cddf Mon Sep 17 00:00:00 2001 From: green Date: Tue, 5 Dec 2000 02:20:19 +0000 Subject: Import of OpenSSH 2.3.0 (virgin OpenBSD source release). --- crypto/openssh/auth-rhosts.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'crypto/openssh/auth-rhosts.c') diff --git a/crypto/openssh/auth-rhosts.c b/crypto/openssh/auth-rhosts.c index 901c8d1..8314e23 100644 --- a/crypto/openssh/auth-rhosts.c +++ b/crypto/openssh/auth-rhosts.c @@ -14,7 +14,7 @@ */ #include "includes.h" -RCSID("$OpenBSD: auth-rhosts.c,v 1.15 2000/09/07 20:27:49 deraadt Exp $"); +RCSID("$OpenBSD: auth-rhosts.c,v 1.16 2000/10/03 18:03:03 markus Exp $"); #include "packet.h" #include "ssh.h" @@ -154,6 +154,9 @@ auth_rhosts(struct passwd *pw, const char *client_user) static const char *rhosts_files[] = {".shosts", ".rhosts", NULL}; unsigned int rhosts_file_index; + /* no user given */ + if (pw == NULL) + return 0; /* Switch to the user's uid. */ temporarily_use_uid(pw->pw_uid); /* -- cgit v1.1