[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 8/8] XXX fix the size of ipc_port structs
From: |
Justus Winter |
Subject: |
[PATCH 8/8] XXX fix the size of ipc_port structs |
Date: |
Fri, 29 Nov 2013 01:00:40 +0100 |
I do not know why this is happening, but w/o this, some kernel
pointers leak into the ip_protected_payload field. So it looks like
sizeof(struct ipc_tree_entry) is wrong here, not sure why
though. Maybe the global header is imported? But the compiler flags
should prevent this...
---
ipc/ipc_init.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ipc/ipc_init.c b/ipc/ipc_init.c
index ca7e791..092c6e0 100644
--- a/ipc/ipc_init.c
+++ b/ipc/ipc_init.c
@@ -80,7 +80,7 @@ ipc_bootstrap(void)
sizeof(struct ipc_tree_entry), 0, NULL, NULL, NULL, 0);
kmem_cache_init(&ipc_object_caches[IOT_PORT], "ipc_port",
- sizeof(struct ipc_port), 0, NULL, NULL, NULL, 0);
+ sizeof(struct ipc_port)+4, 0, NULL, NULL, NULL, 0);
kmem_cache_init(&ipc_object_caches[IOT_PORT_SET], "ipc_pset",
sizeof(struct ipc_pset), 0, NULL, NULL, NULL, 0);
--
1.7.10.4
- Implementing protected payloads in GNU Mach, mig, and the Hurd, Justus Winter, 2013/11/29
- [PATCH 1/8] include: skip routines related to migrating threads, Justus Winter, 2013/11/28
- [PATCH 4/8] include: add msgh_protected_payload to mach_msg_header_t, Justus Winter, 2013/11/28
- [PATCH 3/8] ipc: implement mach_port_set_protected_payload, Justus Winter, 2013/11/28
- [PATCH 2/8] ipc: add protected payload, Justus Winter, 2013/11/28
- [PATCH 5/8] include: define MACH_MSG_TYPE_PROTECTED_PAYLOAD, Justus Winter, 2013/11/28
- [PATCH 6/8] ipc: provide the protected payload in ipc_kmsg_copyout_header, Justus Winter, 2013/11/28
- [PATCH 7/8] ipc: clear the payload when moving a receive port, Justus Winter, 2013/11/28
- [PATCH 8/8] XXX fix the size of ipc_port structs,
Justus Winter <=
- [PATCH 1/5] Advise flex not to generate the input function, Justus Winter, 2013/11/28
- [PATCH] Drop the auto keyword, Justus Winter, 2013/11/28
- [PATCH 4/5] Clean up generated sources, Justus Winter, 2013/11/28
- [PATCH 2/5] Avoid a compiler warning in WriteDefines, Justus Winter, 2013/11/28
- [PATCH 3/5] Add inTransPayload, Justus Winter, 2013/11/28
- [PATCH 5/5] Use inTransPayload, Justus Winter, 2013/11/28
- [PATCH 01/23] trans: fix the receiver lookup in password, Justus Winter, 2013/11/28