Re: Passing a char** to a Kext from user mode
Re: Passing a char** to a Kext from user mode
- Subject: Re: Passing a char** to a Kext from user mode
- From: Marek Kozubal <email@hidden>
- Date: Fri, 2 Jul 2004 13:48:39 -0400 (EDT)
On Fri, 2 Jul 2004, Marek Kozubal wrote:
Generally, you send a pointer (ie char *) to your kext via some
communications method. Then inside the kernel you use copyinstr()/copyin()
to get the string into the kernel, or copyoutstr()/copyout() to put it back
to user space. You don't use a char **. You have to create a buffer in user
space, then create a buffer in kernel space and copy the data back and forth.
I just realized, that I should have mentioned this is for kext's that are
not IOKit kext's. If you're in IOKit you use GetProperty()/SetProperty()
type methods.
---
Marek Kozubal
email@hidden
_______________________________________________
darwin-kernel mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/darwin-kernel
Do not post admin requests to the list. They will be ignored.