Netdev List
 help / color / mirror / Atom feed
From: "senthil kumar" <psenthilkumar.accet@gmail.com>
To: bidulock@openss7.org, sigtran@ietf.org
Cc: linux-net@vger.kernel.org, netdev@vger.kernel.org
Subject: SCTP Notification
Date: Fri, 14 Dec 2007 10:07:19 +0900	[thread overview]
Message-ID: <9b936a040712131707p4aba0d51w6c5f3fdd9f6e9543@mail.gmail.com> (raw)


[-- Attachment #1.1: Type: text/plain, Size: 1162 bytes --]

Hi,

    I am using SCTP(libsctp) in linux 2.6.9. I have subscribed for
Notifications. However, i am not getting any notification when sctp
association is established or peer is shutdown. Is there any correction in
my method of subscription? setsockopt system call is returning success. i
used getsockopt to verify the same.

      struct sockaddr_in stSrcIPAddress;
      socklen_t  Addlen=sizeof(sockaddr_in);
      int  iFlags=-1,iRet=-1;

      struct sctp_sndrcvinfo sndrcvinfo;
      struct sctp_event_subscribe events;

  memset( (void *)&events, 0, sizeof(events) );
  events.sctp_data_io_event = 1;
  events.sctp_association_event = 1;
  events.sctp_send_failure_event = 1;
  events.sctp_shutdown_event = 1;
  events.sctp_peer_error_event = 1;

  ret = setsockopt( iconnSock, IPPROTO_SCTP, SCTP_EVENTS,(const void
*)&events, sizeof(events) );
  while(1)
  {
    iRet = sctp_recvmsg(iconnSock, (void *)pacbuffer,600, (struct sockaddr
*)&stSrcIPAddress, &Addlen, &sndrcvinfo, &iFlags );
    if ( iRet < 0)
    {
    }
    if(iFlags & MSG_NOTIFICATION )//Notification/event is received.
    {
    }
    if (iRet> 0)
    {
    }
}

with regards,
   senthil

[-- Attachment #1.2: Type: text/html, Size: 1740 bytes --]

[-- Attachment #2: Type: text/plain, Size: 133 bytes --]

_______________________________________________
Sigtran mailing list
Sigtran@ietf.org
https://www1.ietf.org/mailman/listinfo/sigtran

                 reply	other threads:[~2007-12-14  1:07 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9b936a040712131707p4aba0d51w6c5f3fdd9f6e9543@mail.gmail.com \
    --to=psenthilkumar.accet@gmail.com \
    --cc=bidulock@openss7.org \
    --cc=linux-net@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=sigtran@ietf.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox