From ea0650c4cf72dcfc6322c381effd9650b3890fd7 Mon Sep 17 00:00:00 2001 From: Thomas Bushnell Date: Sat, 6 Mar 1999 22:18:34 +0000 Subject: 1999-03-06 Mark Kettenis * notify.c (do_mach_notify_dead_name): Deallocate reference to DEADPORT. --- proc/notify.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'proc/notify.c') diff --git a/proc/notify.c b/proc/notify.c index 9d48d945..7ab8d56b 100644 --- a/proc/notify.c +++ b/proc/notify.c @@ -1,5 +1,5 @@ /* Handle notifications - Copyright (C) 1992, 1993, 1994, 1996 Free Software Foundation, Inc. + Copyright (C) 1992, 1993, 1994, 1996, 1999 Free Software Foundation, Inc. This file is part of the GNU Hurd. @@ -41,6 +41,9 @@ do_mach_notify_dead_name (mach_port_t notify, { struct proc *p; + /* Drop gratuitous extra reference that the notification creates. */ + mach_port_deallocate (mach_task_self (), deadport); + if (notify == generic_port) { check_dead_execdata_notify (deadport); @@ -50,7 +53,9 @@ do_mach_notify_dead_name (mach_port_t notify, p = ports_lookup_port (proc_bucket, notify, proc_class); if (!p) - return EOPNOTSUPP; + { + return EOPNOTSUPP; + } if (p->p_msgport == deadport) { -- cgit v1.2.3