Re: Writing from the kernel
Re: Writing from the kernel
- Subject: Re: Writing from the kernel
- From: Terry Lambert <email@hidden>
- Date: Tue, 20 Nov 2007 14:58:39 -0800
Actually both UNIX/POSIX and ANSI/ISO C standards require that
prototypeseither be omitted or in the implementation name space --
have underscore prefixes so if a user e.g. does:
#define path "mypath"
and then #includes a system header to get e.g.:
Int open(const char *path, int flags, ...);
In scope, path in the parameter list doesn't change into something
else that's syntactically incorrect (or worse, syntactically correct
but wrong).
Unfortunately, there's user code out there that puts variables and
definitions into that space anyway, so we just try to avoid it all.
-- Terry
On Nov 20, 2007, at 8:01 AM, Quinn <email@hidden> wrote:
At 9:54 -0600 20/11/07, Kynan Shook wrote:
Now, is there any documentation on these interfaces? A google on
vnode_open returns very few results...
Not really )-: [1] And given the BSD habit of not including formal
parameter names in prototypes [2], your only real option is to look
at the Darwin source.
S+E
--
Quinn "The Eskimo!" <http://www.apple.com/developer/
>
Apple Developer Relations, Developer Technical Support, Core OS/
Hardware
[1] The bug tracking this is <rdar://problem/3524590>.
[2] Alas, there are fairly good technical reasons for this.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden