diff options
author | Darren Tucker <dtucker@zip.com.au> | 2004-08-13 21:29:02 +1000 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2004-08-13 21:29:02 +1000 |
commit | 1ef0bc0b0a6104af6b37b525e52b7a20abb532a9 (patch) | |
tree | 7420133ab178d9fb3f3ded7f301a9ee931e8e490 /monitor_fdpass.c | |
parent | 6e37037fea62948a5481e83750c9fbbd05f41831 (diff) | |
download | openssh-git-1ef0bc0b0a6104af6b37b525e52b7a20abb532a9.tar.gz |
- djm@cvs.openbsd.org 2004/08/13 02:51:48
[monitor_fdpass.c]
extra check for no message case; ok markus, deraadt, hshoexer, henning
Diffstat (limited to 'monitor_fdpass.c')
-rw-r--r-- | monitor_fdpass.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/monitor_fdpass.c b/monitor_fdpass.c index f0dd88e7..dd1a1398 100644 --- a/monitor_fdpass.c +++ b/monitor_fdpass.c @@ -24,7 +24,7 @@ */ #include "includes.h" -RCSID("$OpenBSD: monitor_fdpass.c,v 1.5 2004/06/21 17:36:31 avsm Exp $"); +RCSID("$OpenBSD: monitor_fdpass.c,v 1.6 2004/08/13 02:51:48 djm Exp $"); #include <sys/uio.h> @@ -113,6 +113,8 @@ mm_receive_fd(int sock) fatal("%s: no fd", __func__); #else cmsg = CMSG_FIRSTHDR(&msg); + if (cmsg == NULL) + fatal("%s: no message header", __func__); #ifndef BROKEN_CMSG_TYPE if (cmsg->cmsg_type != SCM_RIGHTS) fatal("%s: expected type %d got %d", __func__, |