SCTP Discussions

Text archives Help


[SCTP-Discussion] Re: Return value for sctp_registerInstance


Chronological Thread 
  • From: Andreas Jungmaier <ajung AT exp-math.uni-essen.de>
  • To: Sim Woon Chiat ICM CA MS MI E7 Extern <WoonChiat.Sim.extern AT icn.siemens.de>
  • Cc: discussion AT sctp.de
  • Subject: [SCTP-Discussion] Re: Return value for sctp_registerInstance
  • Date: Wed Jul 4 15:04:01 2001
  • List-id: SCTP Discussions <discussion.sctp.de>
  • Organization: University of Essen, Germany

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wednesday, 4. July 2001 08:42, Sim Woon Chiat ICM CA MS MI E7 Extern
wrote:
> hi,
>
> would like to clarify the following :
>
> when we call sctp_registerInstance( ) with localPort = 0, we get a 0 as the
> return value. Does that mean that if we are to use the library for a client
> application that wishes to use any freely available port, we will not get
> the instance name / id? Or is the creation of the instance delayed until a
> sctp_associate( ) is called? This seems unlikely as if a port is
> specified, we do get a instance name / id.

This is a bug on my behalf (a bit of too-eager error checking ;-)
Apply the following patch:

diff -r1.36 distribution.c
1315c1315
< if ((port == 0) || (noOfInStreams==0) || (noOfOutStreams == 0) ||
- ---
> if ((noOfInStreams==0) || (noOfOutStreams == 0) ||


It will be applied in the next subrelease, probably also due end of this
week.

Then you will get the semantics as described in the manual, i.e. you
will *not* get 0 as return value, and once sctp_associate is called,
your association will have a port number chosen by the library.

> thanks for your attention.
Thanks for posting this !

Andreas

- ----------------------------------------------------------------------------
\|/ _____ \|/ Andreas Jungmaier, Dipl.-Ing.
"@'/ , . \`@" University of Essen
ajung AT exp-math.uni-essen.de
/_| \___/ |__\ -> Computer Networking Tel. : +49 (0201) 183-7636
\___U_/ Technology Group <-
- ----------------------------------------------------------------------------
PGP Public Key and Fingerprint: see http://www.exp-math.uni-essen.de/~ajung
- ----------------------------------------------------------------------------
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.5 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE7Q2iNd2Uw+xBvGUIRApXXAJ9eqViHgSOjR7oPjQv9zmRkDQ7vcQCZAUDm
z2c/U0JeiM6h5O5sRerj2sg=
=AvCo
-----END PGP SIGNATURE-----




Archive powered by MHonArc 2.6.19+.

Top of page