lwip-members
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-members] LWIP_COMPAT_SOCKETS


From: Kieran Mansley
Subject: Re: [lwip-members] LWIP_COMPAT_SOCKETS
Date: Fri, 28 Feb 2003 08:47:06 +0000 (GMT)

On Fri, 28 Feb 2003, Jani Monoses wrote:

> Hi Kieran
> what you fear is what I intended to do but realised it breaks at least
> the unix simulator.It was one of my overzealous attempts at cleaning the code 
> :)
> Out of curiosity why would that be a problem to you?It is because you run
> on a platform where these names would clash with system functions right?
> But yes the compat flag seems of not too much use maybe that will go away
> and the macros will default to lwip_xxx

It's not so much that the names would clash, but that I need to use both.
In the sockets code I check the file descriptor passed to each function,
and if it's not one I've allocated I pass it on to the system sockets
functions (and so need to be able to call them by name without it
resulting in a call to the lwip ones).  I achieve this by temporarily
undefining LWIP_COMPAT_SOCKETS when including sockets.h in sockets.c
This allows an application to still read() and write() to stdin and stdout
for example.

Kieran





reply via email to

[Prev in Thread] Current Thread [Next in Thread]