mirror of
https://git.rtems.org/rtems-libbsd/
synced 2025-10-15 03:17:56 +08:00
Update to FreeBSD head 2016-08-23
Git mirror commit 9fe7c416e6abb28b1398fd3e5687099846800cfd.
This commit is contained in:
@@ -35,18 +35,25 @@ static char sccsid[] = "@(#)send.c 8.2 (Berkeley) 2/21/94";
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "namespace.h"
|
||||
#include <sys/types.h>
|
||||
#include <sys/socket.h>
|
||||
#include "libc_private.h"
|
||||
|
||||
#include <stddef.h>
|
||||
#include "un-namespace.h"
|
||||
|
||||
ssize_t
|
||||
send(s, msg, len, flags)
|
||||
int s, flags;
|
||||
size_t len;
|
||||
const void *msg;
|
||||
send(int s, const void *msg, size_t len, int flags)
|
||||
{
|
||||
return (_sendto(s, msg, len, flags, NULL, 0));
|
||||
/*
|
||||
* POSIX says send() shall be a cancellation point, so call the
|
||||
* cancellation-enabled sendto() and not _sendto().
|
||||
*/
|
||||
#ifndef __rtems__
|
||||
return (((ssize_t (*)(int, const void *, size_t, int,
|
||||
const struct sockaddr *, socklen_t))
|
||||
__libc_interposing[INTERPOS_sendto])(s, msg, len, flags,
|
||||
NULL, 0));
|
||||
#else /* __rtems__ */
|
||||
return (sendto(s, msg, len, flags, NULL, 0));
|
||||
#endif /* __rtems__ */
|
||||
}
|
||||
|
Reference in New Issue
Block a user