From 7d44d1ff0ec4077e569c9b8449dd71b354e5ad65 Mon Sep 17 00:00:00 2001 From: "Michael I. Bushnell" Date: Fri, 9 Jun 1995 21:14:08 +0000 Subject: (diskfs_S_io_get_icky_async_id): Validate CRED. --- libdiskfs/io-async-icky.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libdiskfs/io-async-icky.c b/libdiskfs/io-async-icky.c index 93ef8f50..22cb3abb 100644 --- a/libdiskfs/io-async-icky.c +++ b/libdiskfs/io-async-icky.c @@ -1,5 +1,5 @@ /* - Copyright (C) 1994 Free Software Foundation + Copyright (C) 1994, 1995 Free Software Foundation This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as @@ -24,6 +24,9 @@ diskfs_S_io_get_icky_async_id (struct protid *cred, mach_port_t *idport, mach_msg_type_name_t *idport_type) { + if (!cred) + return EOPNOTSUPP; + *idport = MACH_PORT_NULL; *idport_type = MACH_MSG_TYPE_COPY_SEND; return 0; -- cgit v1.2.3