SCTP Discussions

Text archives Help


Re: [SCTP-Discussion] a weird bug (segmentation fault)


Chronological Thread 
  • From: Thomas Dreibholz <dreibh AT iem.uni-due.de>
  • To: "Julio Kriger" <juliokriger AT gmail.com>
  • Cc: discussion AT sctp.de
  • Subject: Re: [SCTP-Discussion] a weird bug (segmentation fault)
  • Date: Wed May 31 12:02:02 2006
  • List-id: SCTP Discussions <discussion.sctp.de>

On Sunday 28 May 2006 05:01, Julio Kriger wrote:
> Hi!
> I made the app thread safe. Every call to the sctp library is done through
> a mutex. and I have another mutex for sctp_extendedEventLoop. I tried to
> use only one mutex, but I stated to get locking problems. I hope this is
> correct.

The must be a single mutex. Otherwise, there may be situations where two
threads simultaneously access sctplib structures - which will lead to
problems.

If you send me the source code, I can have a look at it.


> Now many times I get a core dump, but it's of no use to read it with ddd or
> gdb, it pints to nowhere (I compiled sctplib with -ggdg option). And when I

Did you have compiled your program itself with the debug option? If the
problem is in the program itself, gdb only shows the address when no debug
option is set.


> don't get the "holy" core dump

If no core dump is created upon segmentation fault, the core dump size limit
may be too small. Try "ulimit -c unlimited" (bash shell).

To find bugs, also try Valgrind (http://valgrind.org/). This is a very great
tool to detect problems.


> I get this messages several times: "
> Bad > ctsna arrived in SACK or no data in queue - discarding SACK".

These messages can be ignored, they are debug output of the sctplib.


> I don't know what I'm doing wrong. Maybe I should use the socket api...
> Feel free to share any thought about this.

This would probably be the easiest solution.


Best regards
--
=======================================================================
Dipl.-Inform. Thomas Dreibholz

University of Essen, Room ES210
Inst. for Experimental Mathematics Ellernstraße 29
Computer Networking Technology Group D-45326 Essen/Germany
-----------------------------------------------------------------------
E-Mail:
dreibh AT exp-math.uni-essen.de
Homepage: http://www.exp-math.uni-essen.de/~dreibh
=======================================================================

Attachment: pgpg0ODpSirH1.pgp
Description: PGP signature




Archive powered by MHonArc 2.6.19+.

Top of page