> There are times when you want to use low level unix system calls in
> your carbon application. It's trivial but some syscalls needs file
[quoted text clipped - 3 lines]
> at hand. There is no official way to map this filerefnum to file
> descriptor.
Can you give us some example when your code (which relies on undocumented
behavior that might change in a new OS release) is better than simply getting
the path from the Carbon file ref and using that path with POSIX calls?
Ben

Signature
If this message helped you, consider buying an item
from my wish list: <http://artins.org/ben/wishlist>
I changed my name: <http://periodic-kingdom.org/People/NameChange.php>
--
Posted via a free Usenet account from http://www.teranews.com
piyuesh@gmail.com - 30 Jun 2006 10:22 GMT
> > There are times when you want to use low level unix system calls in
> > your carbon application. It's trivial but some syscalls needs file
[quoted text clipped - 11 lines]
>
> --
for example fcntl, flock etc..works on file descriptor not on
pathnames, also there may be some other usage for this method. I'm not
able to think every possible scenario right now.
Piyuesh
Ben Artin - 30 Jun 2006 17:16 GMT
> > > There are times when you want to use low level unix system calls in your
> > > carbon application. It's trivial but some syscalls needs file descriptor
[quoted text clipped - 13 lines]
> there may be some other usage for this method. I'm not able to think every
> possible scenario right now.
OK, so once you have the path, call fopen() yourself. That's a much better
idea than relying on the undocumented implementation details of Apple APIs.
Ben

Signature
If this message helped you, consider buying an item
from my wish list: <http://artins.org/ben/wishlist>
I changed my name: <http://periodic-kingdom.org/People/NameChange.php>
--
Posted via a free Usenet account from http://www.teranews.com