summaryrefslogtreecommitdiffstats
path: root/lib/libc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/net/sctp_sys_calls.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/libc/net/sctp_sys_calls.c b/lib/libc/net/sctp_sys_calls.c
index 30f7fcc..dcbcee7 100644
--- a/lib/libc/net/sctp_sys_calls.c
+++ b/lib/libc/net/sctp_sys_calls.c
@@ -700,14 +700,19 @@ sctp_sendx(int sd, const void *msg, size_t msg_len,
#ifdef SYS_sctp_generic_sendmsg
if (addrcnt == 1) {
socklen_t l;
+ ssize_t ret;
/*
* Quick way, we don't need to do a connectx so lets use the
* syscall directly.
*/
l = addrs->sa_len;
- return (syscall(SYS_sctp_generic_sendmsg, sd,
- msg, msg_len, addrs, l, sinfo, flags));
+ ret = syscall(SYS_sctp_generic_sendmsg, sd,
+ msg, msg_len, addrs, l, sinfo, flags);
+ if ((ret >= 0) && (sinfo != NULL)) {
+ sinfo->sinfo_assoc_id = sctp_getassocid(sd, addrs);
+ }
+ return (ret);
}
#endif
OpenPOWER on IntegriCloud