curl-users
Re: Curl 7.9.3 pre3 build fails
Date: Fri, 18 Jan 2002 16:47:54 -0500
On 1/18/02 3:20 AM, "Daniel Stenberg" <daniel_at_haxx.se> wrote:
> On Thu, 17 Jan 2002, Saul Good wrote:
>
>> Using Mac OS X 10.1.2 and Dec dev tools:
>>
>> sendf.c: In function `Curl_write':
>> sendf.c:232: `EWOULDBLOCK' undeclared (first use in this function)
>> sendf.c:344: `EWOULDBLOCK' undeclared (first use in this function)
>> sendf.c:344: `errno' undeclared (first use in this function)
>
> Hm
>
> Can you check this out a bit further for us? I don't have access to any Mac
> OS X machines myself.
>
> Try the man pages for 'recv()' and 'send()', they should mention which
> include files to use to get the EWOULDBLOCK definition. Mac OS X simply *has*
> to have it, I just think we don't include the proper header. Or try grepping
> among all headers to see where it might be.
>
> The same goes with errno there. Invoke 'man errno' and check which include
> file we need to include. Hm, you could even try to add:
>
> #include <errno.h>
>
> I noticed we don't have that included, although we probably should.
Sure,
The includes for recv() are as follows:
#include <sys/types.h>
#include <sys/socket.h>
ssize_t
recv(int s, void *buf, size_t len, int flags)
ssize_t
recvfrom(int s, void *buf, size_t len, int flags, struct sockaddr
*from,
int *fromlen)
ssize_t
recvmsg(int s, struct msghdr *msg, int flags)
And for send()
#include <sys/types.h>
#include <sys/socket.h>
ssize_t
send(int s, const void *msg, size_t len, int flags)
ssize_t
sendto(int s, const void *msg, size_t len, int flags,
const struct sockaddr *to, int tolen)
ssize_t
sendmsg(int s, const struct msghdr *msg, int flags)
There is no manpage for errno but there is an:
/usr/include/sys/errno.h
And
/System/Library/Frameworks/Kernel.framework/Versions/A/Headers/sys/errno.h
-saul
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com
Received on 2002-01-18