=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ssh/uidswap.c,v retrieving revision 1.27 retrieving revision 1.28 diff -u -r1.27 -r1.28 --- src/usr.bin/ssh/uidswap.c 2006/04/22 04:06:51 1.27 +++ src/usr.bin/ssh/uidswap.c 2006/06/06 10:20:20 1.28 @@ -1,4 +1,4 @@ -/* $OpenBSD: uidswap.c,v 1.27 2006/04/22 04:06:51 djm Exp $ */ +/* $OpenBSD: uidswap.c,v 1.28 2006/06/06 10:20:20 markus Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -111,6 +111,8 @@ void permanently_set_uid(struct passwd *pw) { + if (pw == NULL) + fatal("permanently_set_uid: no user given"); if (temporarily_use_uid_effective) fatal("permanently_set_uid: temporarily_use_uid effective"); debug("permanently_set_uid: %u/%u", (u_int)pw->pw_uid,