summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libthreads/mig_support.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/libthreads/mig_support.c b/libthreads/mig_support.c
index 52936505..bb9e6a5e 100644
--- a/libthreads/mig_support.c
+++ b/libthreads/mig_support.c
@@ -174,3 +174,21 @@ __mig_dealloc_reply_port ()
{
mig_dealloc_reply_port ();
}
+
+/* XXX shouldn't need these */
+/* Called by MiG to allocate space. */
+void
+__mig_allocate (vm_address_t *addr,
+ vm_size_t size)
+{
+ if (__vm_allocate (__mach_task_self (), addr, size, 1) != KERN_SUCCESS)
+ *addr = 0;
+}
+
+/* Called by MiG to deallocate space. */
+void
+__mig_deallocate (vm_address_t addr,
+ vm_size_t size)
+{
+ (void) __vm_deallocate (__mach_task_self (), addr, size);
+}