mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
sctp: add subscribe per asoc
The member subscribe should be per asoc, so that sockopt SCTP_EVENT in the next patch can subscribe a event from one asoc only. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
2cc0eeb676
commit
a1e3a0590f
6 changed files with 17 additions and 10 deletions
|
@ -86,11 +86,10 @@ void sctp_datamsg_free(struct sctp_datamsg *msg)
|
|||
/* Final destructruction of datamsg memory. */
|
||||
static void sctp_datamsg_destroy(struct sctp_datamsg *msg)
|
||||
{
|
||||
struct sctp_association *asoc = NULL;
|
||||
struct list_head *pos, *temp;
|
||||
struct sctp_chunk *chunk;
|
||||
struct sctp_sock *sp;
|
||||
struct sctp_ulpevent *ev;
|
||||
struct sctp_association *asoc = NULL;
|
||||
int error = 0, notify;
|
||||
|
||||
/* If we failed, we may need to notify. */
|
||||
|
@ -108,8 +107,7 @@ static void sctp_datamsg_destroy(struct sctp_datamsg *msg)
|
|||
else
|
||||
error = asoc->outqueue.error;
|
||||
|
||||
sp = sctp_sk(asoc->base.sk);
|
||||
notify = sctp_ulpevent_type_enabled(sp->subscribe,
|
||||
notify = sctp_ulpevent_type_enabled(asoc->subscribe,
|
||||
SCTP_SEND_FAILED);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue