Bug 828154: reapply local patches to netwerk/sctp/src rs=mcmanus

This commit is contained in:
Randell Jesup 2013-01-10 17:20:23 -05:00
parent 0567b6e5db
commit 135f08ca84
8 changed files with 32 additions and 2 deletions

View File

@ -49,8 +49,13 @@ __FBSDID("$FreeBSD: head/sys/netinet/sctp_bsd_addr.c 239035 2012-08-04 08:03:30Z
#include <netinet/sctp_sysctl.h>
#include <netinet/sctp_indata.h>
#if !defined(__Userspace_os_Windows)
#if defined(ANDROID)
#include <unistd.h>
#include <ifaddrs-android-ext.h>
#else
#include <sys/unistd.h>
#endif
#endif
/* Declare all of our malloc named types */
#ifndef __Panda__

View File

@ -381,7 +381,7 @@ struct udphdr {
#else /* !defined(Userspace_os_Windows) */
#include <sys/cdefs.h> /* needed? added from old __FreeBSD__ */
#include <sys/socket.h>
#if defined(__Userspace_os_FreeBSD)
#if defined(__Userspace_os_FreeBSD) || defined(__Userspace_os_Linux) || defined(__Userspace_os_Android)
#include <pthread.h>
#endif
typedef pthread_mutex_t userland_mutex_t;
@ -461,7 +461,9 @@ struct sx {int dummy;};
/* for getifaddrs */
#include <sys/types.h>
#if !defined(__Userspace_os_Windows)
#if !defined(ANDROID)
#include <ifaddrs.h>
#endif
/* for ioctl */
#include <sys/ioctl.h>

View File

@ -69,8 +69,13 @@ __FBSDID("$FreeBSD: head/sys/netinet/sctp_pcb.c 244729 2012-12-27 08:06:58Z tuex
#endif
#if defined(__Userspace__)
#if !defined(__Userspace_os_Windows)
#if defined(ANDROID)
#include <unistd.h>
#include <ifaddrs-android-ext.h>
#else
#include <sys/unistd.h>
#endif
#endif
#include <user_socketvar.h>
#endif

View File

@ -34,8 +34,10 @@
#if !defined (__Userspace_os_Windows)
#include <stdint.h>
#if !defined(__Userspace_os_FreeBSD)
#if !defined(ANDROID)
#include <sys/sysctl.h>
#endif
#endif
#include <netinet/sctp_os_userspace.h>
#endif
#include <user_environment.h>

View File

@ -35,6 +35,13 @@
#include <user_route.h> /* was <net/route.h> */
#if defined(ANDROID)
#include <arpa/inet.h>
#include <netinet/in.h>
/* missing defines in Android bionic libc/NDK */
typedef uint16_t in_port_t;
#endif
#define in6pcb inpcb /* for KAME src sync over BSD*'s */
#define in6p_sp inp_sp /* for KAME src sync over BSD*'s */
struct inpcbpolicy;

View File

@ -442,6 +442,7 @@ recv_function_raw(void *arg)
#else
pthread_exit(NULL);
#endif
return NULL;
}
#endif
@ -625,6 +626,7 @@ recv_function_raw6(void *arg)
#else
pthread_exit(NULL);
#endif
return NULL;
}
#endif
@ -829,6 +831,7 @@ recv_function_udp(void *arg)
#else
pthread_exit(NULL);
#endif
return NULL;
}
#endif
@ -1015,6 +1018,7 @@ recv_function_udp6(void *arg)
#else
pthread_exit(NULL);
#endif
return NULL;
}
#endif

View File

@ -37,6 +37,11 @@
#include <sys/types.h>
#include <unistd.h>
#endif
#if defined(ANDROID)
/* Android bionic libc is missing some defines in sys/types.h. Pick them
* up elsewhere */
#include <linux/coda.h>
#endif
/* #include <sys/selinfo.h> */ /*__Userspace__ alternative?*/ /* for struct selinfo */
/* #include <sys/_lock.h> was 0 byte file */

View File

@ -968,7 +968,7 @@ usrsctp_register_address(void *);
void
usrsctp_deregister_address(void *);
#define SCTP_DUMP_OUTBOUND 1
#define SCTP_DUMP_OUTBOUND 0
#define SCTP_DUMP_INBOUND 0
char *