summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustus Winter <4winter@informatik.uni-hamburg.de>2015-01-20 20:10:08 +0100
committerJustus Winter <4winter@informatik.uni-hamburg.de>2015-01-20 20:30:29 +0100
commitccee70dd9fc20a5b39c59b0a7dc8c72e2536ede9 (patch)
tree9bae90c1f82623c29fcc5a8849867f1fa080df46
parent508221b49ae825501882e228b18e4586e59e88b0 (diff)
utils/rpctrace: fix notification port handling
* utils/rpctrace.c (new_receiver_info): Fix handling of old notification port.
-rw-r--r--utils/rpctrace.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/utils/rpctrace.c b/utils/rpctrace.c
index 62d3c876..48daa078 100644
--- a/utils/rpctrace.c
+++ b/utils/rpctrace.c
@@ -404,7 +404,8 @@ new_receiver_info (mach_port_t right, mach_port_t owner)
MACH_MSG_TYPE_MAKE_SEND_ONCE, &foo);
if (err)
error (2, err, "mach_port_request_notification");
- mach_port_deallocate (mach_task_self (), foo);
+ if (MACH_PORT_VALID (foo))
+ mach_port_deallocate (mach_task_self (), foo);
err = hurd_ihash_add (&traced_names, info->forward, info);
if (err)