"Waxhead" <zo****@online.nowrote in message
news:11**********************@48g2000cwx.googlegro ups.com...
Stephen Sprunk wrote:
>Standard C does not acknowledge that more than one program exists, so
therefore it does not provide any mechanisms for IPC.
Your platform likely provides APIs to do this, however. Win32/64 and
POSIX both do, but of course it's off-topic here. Check in a
newsgroup
for your particular platform.
My problem is that I'm going to run my program on two platforms
(Windows and Linux). This is one of the reasons that I'm searching for
a independent way of doing this.
Windows and POSIX may provide similar mechanisms; for instance most
sockets code is the same between the two, though Windows does require a
few extra calls and has slightly different prototypes for some functions
(like using int instead of size_t). They're close enough that you can
write code that will work on both, with the occasional #ifdef for the
OS-specific cruft.
If you want something more powerful, though, they diverge pretty
rapidly. Your best bet is to find a library that provides wrappers to
various OSes and presents a common API to your code. Obviously, that
limits your program's portability to wherever that library works, but
that may not be an issue for you. If you can't find a suitable library,
then write your own (as described above) and publish it :)
S
--
Stephen Sprunk "God does not play dice." --Albert Einstein
CCIE #3723 "God is an inveterate gambler, and He throws the
K5SSS dice at every possible opportunity." --Stephen Hawking
--
Posted via a free Usenet account from
http://www.teranews.com