diff options
author | tom <tom@a5019735-40e9-0310-863c-91ae7b9d1cf9> | 2005-08-28 10:16:29 +0000 |
---|---|---|
committer | tom <tom@a5019735-40e9-0310-863c-91ae7b9d1cf9> | 2005-08-28 10:16:29 +0000 |
commit | 1aa57373be5343c365ee6b480e205abc16008402 (patch) | |
tree | b872b3f4efc8729236799096b05b1567a6795657 /include | |
parent | 62a319071ae9243f63609546bc23d899e73ba6ec (diff) |
Handle the SCTP_GET_LOCAL_ADDRS and SCTP_GET_PEER_ADDRS getsockopt
calls correctly. Fix to bug #111231.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@4549 a5019735-40e9-0310-863c-91ae7b9d1cf9
Diffstat (limited to 'include')
-rw-r--r-- | include/vki-amd64-linux.h | 1 | ||||
-rw-r--r-- | include/vki-linux.h | 69 | ||||
-rw-r--r-- | include/vki-ppc32-linux.h | 1 | ||||
-rw-r--r-- | include/vki-x86-linux.h | 1 |
4 files changed, 72 insertions, 0 deletions
diff --git a/include/vki-amd64-linux.h b/include/vki-amd64-linux.h index d1c28769..7eb1906f 100644 --- a/include/vki-amd64-linux.h +++ b/include/vki-amd64-linux.h @@ -44,6 +44,7 @@ typedef unsigned char __vki_u8; typedef __signed__ short __vki_s16; typedef unsigned short __vki_u16; +typedef __signed__ int __vki_s32; typedef unsigned int __vki_u32; typedef __signed__ long long __vki_s64; diff --git a/include/vki-linux.h b/include/vki-linux.h index 6868e3b3..5d6df36c 100644 --- a/include/vki-linux.h +++ b/include/vki-linux.h @@ -587,6 +587,8 @@ __KINLINE struct vki_cmsghdr * vki_cmsg_nxthdr (struct vki_msghdr *__msg, struct #define VKI_MSG_NOSIGNAL 0x4000 /* Do not generate SIGPIPE */ +#define VKI_SOL_SCTP 132 + //---------------------------------------------------------------------- // From linux-2.6.8.1/include/linux/in.h //---------------------------------------------------------------------- @@ -772,6 +774,73 @@ struct vki_rtentry }; //---------------------------------------------------------------------- +// From linux-2.6.13-rc5/include/net/sctp/user.h +//---------------------------------------------------------------------- + +typedef __vki_s32 vki_sctp_assoc_t; + +enum vki_sctp_optname { + VKI_SCTP_RTOINFO, +#define VKI_SCTP_RTOINFO VKI_SCTP_RTOINFO + VKI_SCTP_ASSOCINFO, +#define VKI_SCTP_ASSOCINFO VKI_SCTP_ASSOCINFO + VKI_SCTP_INITMSG, +#define VKI_SCTP_INITMSG VKI_SCTP_INITMSG + VKI_SCTP_NODELAY, /* Get/set nodelay option. */ +#define VKI_SCTP_NODELAY VKI_SCTP_NODELAY + VKI_SCTP_AUTOCLOSE, +#define VKI_SCTP_AUTOCLOSE VKI_SCTP_AUTOCLOSE + VKI_SCTP_SET_PEER_PRIMARY_ADDR, +#define VKI_SCTP_SET_PEER_PRIMARY_ADDR VKI_SCTP_SET_PEER_PRIMARY_ADDR + VKI_SCTP_PRIMARY_ADDR, +#define VKI_SCTP_PRIMARY_ADDR VKI_SCTP_PRIMARY_ADDR + VKI_SCTP_ADAPTION_LAYER, +#define VKI_SCTP_ADAPTION_LAYER VKI_SCTP_ADAPTION_LAYER + VKI_SCTP_DISABLE_FRAGMENTS, +#define VKI_SCTP_DISABLE_FRAGMENTS VKI_SCTP_DISABLE_FRAGMENTS + VKI_SCTP_PEER_ADDR_PARAMS, +#define VKI_SCTP_PEER_ADDR_PARAMS VKI_SCTP_PEER_ADDR_PARAMS + VKI_SCTP_DEFAULT_SEND_PARAM, +#define VKI_SCTP_DEFAULT_SEND_PARAM VKI_SCTP_DEFAULT_SEND_PARAM + VKI_SCTP_EVENTS, +#define VKI_SCTP_EVENTS VKI_SCTP_EVENTS + VKI_SCTP_I_WANT_MAPPED_V4_ADDR, /* Turn on/off mapped v4 addresses */ +#define VKI_SCTP_I_WANT_MAPPED_V4_ADDR VKI_SCTP_I_WANT_MAPPED_V4_ADDR + VKI_SCTP_MAXSEG, /* Get/set maximum fragment. */ +#define VKI_SCTP_MAXSEG VKI_SCTP_MAXSEG + VKI_SCTP_STATUS, +#define VKI_SCTP_STATUS VKI_SCTP_STATUS + VKI_SCTP_GET_PEER_ADDR_INFO, +#define VKI_SCTP_GET_PEER_ADDR_INFO VKI_SCTP_GET_PEER_ADDR_INFO + + /* Internal Socket Options. Some of the sctp library functions are + * implemented using these socket options. + */ + VKI_SCTP_SOCKOPT_BINDX_ADD = 100,/* BINDX requests for adding addresses. */ +#define VKI_SCTP_SOCKOPT_BINDX_ADD VKI_SCTP_SOCKOPT_BINDX_ADD + VKI_SCTP_SOCKOPT_BINDX_REM, /* BINDX requests for removing addresses. */ +#define VKI_SCTP_SOCKOPT_BINDX_REM VKI_SCTP_SOCKOPT_BINDX_REM + VKI_SCTP_SOCKOPT_PEELOFF, /* peel off association. */ +#define VKI_SCTP_SOCKOPT_PEELOFF VKI_SCTP_SOCKOPT_PEELOFF + VKI_SCTP_GET_PEER_ADDRS_NUM, /* Get number of peer addresss. */ +#define VKI_SCTP_GET_PEER_ADDRS_NUM VKI_SCTP_GET_PEER_ADDRS_NUM + VKI_SCTP_GET_PEER_ADDRS, /* Get all peer addresss. */ +#define VKI_SCTP_GET_PEER_ADDRS VKI_SCTP_GET_PEER_ADDRS + VKI_SCTP_GET_LOCAL_ADDRS_NUM, /* Get number of local addresss. */ +#define VKI_SCTP_GET_LOCAL_ADDRS_NUM VKI_SCTP_GET_LOCAL_ADDRS_NUM + VKI_SCTP_GET_LOCAL_ADDRS, /* Get all local addresss. */ +#define VKI_SCTP_GET_LOCAL_ADDRS VKI_SCTP_GET_LOCAL_ADDRS + VKI_SCTP_SOCKOPT_CONNECTX, /* CONNECTX requests. */ +#define VKI_SCTP_SOCKOPT_CONNECTX VKI_SCTP_SOCKOPT_CONNECTX +}; + +struct vki_sctp_getaddrs { + vki_sctp_assoc_t assoc_id; + int addr_num; + struct vki_sockaddr *addrs; +}; + +//---------------------------------------------------------------------- // From linux-2.6.8.1/include/linux/resource.h //---------------------------------------------------------------------- diff --git a/include/vki-ppc32-linux.h b/include/vki-ppc32-linux.h index 5d385a5c..cc3d0715 100644 --- a/include/vki-ppc32-linux.h +++ b/include/vki-ppc32-linux.h @@ -44,6 +44,7 @@ typedef unsigned char __vki_u8; typedef __signed__ short __vki_s16; typedef unsigned short __vki_u16; +typedef __signed__ int __vki_s32; typedef unsigned int __vki_u32; typedef __signed__ long long __vki_s64; diff --git a/include/vki-x86-linux.h b/include/vki-x86-linux.h index f713fb32..ae73305a 100644 --- a/include/vki-x86-linux.h +++ b/include/vki-x86-linux.h @@ -43,6 +43,7 @@ typedef unsigned char __vki_u8; typedef __signed__ short __vki_s16; typedef unsigned short __vki_u16; +typedef __signed__ int __vki_s32; typedef unsigned int __vki_u32; typedef __signed__ long long __vki_s64; |