diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2023-12-03 02:06:29 +0100 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2023-12-03 02:06:29 +0100 |
commit | d776a59723b22192d33557d2127e13cb31905382 (patch) | |
tree | 5de81a6cd03af51f8eff0d257b60150a0d55f9ce /hurd/intr-msg.c | |
parent | 3e85650423e47bf87104add14fc2aacad562d260 (diff) | |
download | glibc-d776a59723b22192d33557d2127e13cb31905382.tar glibc-d776a59723b22192d33557d2127e13cb31905382.tar.gz glibc-d776a59723b22192d33557d2127e13cb31905382.tar.bz2 glibc-d776a59723b22192d33557d2127e13cb31905382.zip |
Revert "Update code to handle the new ABI for sending inlined port rights."
This reverts commit 7e23b3c2c008e0b9b5da055e675d40cc27bb10ef.
Diffstat (limited to 'hurd/intr-msg.c')
-rw-r--r-- | hurd/intr-msg.c | 26 |
1 files changed, 2 insertions, 24 deletions
diff --git a/hurd/intr-msg.c b/hurd/intr-msg.c index d52e90449e..24184f827f 100644 --- a/hurd/intr-msg.c +++ b/hurd/intr-msg.c @@ -199,28 +199,6 @@ _hurd_intr_rpc_mach_msg (mach_msg_header_t *msg, __vm_deallocate (__mach_task_self (), (vm_address_t) data, length); } - inline void clean_inlined_ports (mach_port_name_inlined_t *ports) - { - mach_msg_type_number_t i; - switch (name) - { - case MACH_MSG_TYPE_MOVE_SEND: - for (i = 0; i < number; i++) - __mach_port_deallocate (__mach_task_self (), ports[i].name); - if (ty->msgtl_header.msgt_longform) - ty->msgtl_name = MACH_MSG_TYPE_COPY_SEND; - else - ty->msgtl_header.msgt_name = MACH_MSG_TYPE_COPY_SEND; - break; - case MACH_MSG_TYPE_COPY_SEND: - case MACH_MSG_TYPE_MOVE_RECEIVE: - break; - default: - if (MACH_MSG_TYPE_PORT_ANY (name)) - assert (! "unexpected port type in interruptible RPC"); - } - } - char *data; if (ty->msgtl_header.msgt_longform) { @@ -237,11 +215,11 @@ _hurd_intr_rpc_mach_msg (mach_msg_header_t *msg, data = (char *) ty + sizeof (mach_msg_type_t); } - /* Calculate length of data in bytes. */ const vm_size_t length = ((number * size) + 7) >> 3; if (ty->msgtl_header.msgt_inline) { - clean_inlined_ports (data); + /* Calculate length of data in bytes. */ + clean_ports_and_memory (data, length, 0); /* Move to the next argument. */ ty = (void *) PTR_ALIGN_UP (data + length, __alignof__ (uintptr_t)); } |