aboutsummaryrefslogtreecommitdiff
path: root/ipc/ipc_kmsg.c
diff options
context:
space:
mode:
Diffstat (limited to 'ipc/ipc_kmsg.c')
-rw-r--r--ipc/ipc_kmsg.c31
1 files changed, 28 insertions, 3 deletions
diff --git a/ipc/ipc_kmsg.c b/ipc/ipc_kmsg.c
index fb8de249..096769f2 100644
--- a/ipc/ipc_kmsg.c
+++ b/ipc/ipc_kmsg.c
@@ -686,7 +686,10 @@ ipc_kmsg_copyin_header(
entry = ipc_entry_lookup (space, dest_name);
if (entry == IE_NULL)
+ {
+ ipc_entry_lookup_failed (dest_name);
goto abort_async;
+ }
bits = entry->ie_bits;
/* check type bits */
@@ -738,7 +741,10 @@ ipc_kmsg_copyin_header(
entry = ipc_entry_lookup (space, dest_name);
if (entry == IE_NULL)
+ {
+ ipc_entry_lookup_failed (dest_name);
goto abort_request;
+ }
bits = entry->ie_bits;
/* check type bits */
@@ -752,7 +758,10 @@ ipc_kmsg_copyin_header(
entry = ipc_entry_lookup (space, reply_name);
if (entry == IE_NULL)
+ {
+ ipc_entry_lookup_failed (reply_name);
goto abort_request;
+ }
bits = entry->ie_bits;
/* check type bits */
@@ -819,7 +828,10 @@ ipc_kmsg_copyin_header(
entry = ipc_entry_lookup (space, dest_name);
if (entry == IE_NULL)
+ {
+ ipc_entry_lookup_failed (dest_name);
goto abort_reply;
+ }
bits = entry->ie_bits;
/* check and type bits */
@@ -892,6 +904,8 @@ ipc_kmsg_copyin_header(
if (((entry = ipc_entry_lookup(space, notify)) == IE_NULL) ||
((entry->ie_bits & MACH_PORT_TYPE_RECEIVE) == 0)) {
+ if (entry == IE_NULL)
+ ipc_entry_lookup_failed (notify);
is_write_unlock(space);
return MACH_SEND_INVALID_NOTIFY;
}
@@ -916,8 +930,10 @@ ipc_kmsg_copyin_header(
*/
entry = ipc_entry_lookup(space, name);
- if (entry == IE_NULL)
+ if (entry == IE_NULL) {
+ ipc_entry_lookup_failed (name);
goto invalid_dest;
+ }
assert(reply_type != 0); /* because name not null */
@@ -1067,8 +1083,10 @@ ipc_kmsg_copyin_header(
*/
entry = ipc_entry_lookup(space, dest_name);
- if (entry == IE_NULL)
+ if (entry == IE_NULL) {
+ ipc_entry_lookup_failed (dest_name);
goto invalid_dest;
+ }
kr = ipc_right_copyin(space, dest_name, entry,
dest_type, FALSE,
@@ -1123,12 +1141,17 @@ ipc_kmsg_copyin_header(
*/
dest_entry = ipc_entry_lookup(space, dest_name);
- if (dest_entry == IE_NULL)
+ if (dest_entry == IE_NULL) {
+ ipc_entry_lookup_failed (dest_name);
goto invalid_dest;
+ }
reply_entry = ipc_entry_lookup(space, reply_name);
if (reply_entry == IE_NULL)
+ {
+ ipc_entry_lookup_failed (reply_name);
goto invalid_reply;
+ }
assert(dest_entry != reply_entry); /* names are not equal */
assert(reply_type != 0); /* because reply_name not null */
@@ -2093,6 +2116,8 @@ ipc_kmsg_copyout_header(
if (((entry = ipc_entry_lookup(space, notify))
== IE_NULL) ||
((entry->ie_bits & MACH_PORT_TYPE_RECEIVE) == 0)) {
+ if (entry == IE_NULL)
+ ipc_entry_lookup_failed (notify);
is_read_unlock(space);
return MACH_RCV_INVALID_NOTIFY;
}