[Live-devel] segfault in DelayQueue::removeEntry()

Ross Finlayson finlayson at live555.com
Thu Jun 12 22:15:20 PDT 2008


>should the sanity check, at the beginning of the function, be 
>patched in the following  way?
>
>- if (entry == 
><http://www.live555.com/liveMedia/doxygen/html/UsageEnvironment_8hh.html#070d2ce7b6bb7e5c05602aa8c308d0c4>NULL 
>|| 
>entry-><http://www.live555.com/liveMedia/doxygen/html/classDelayQueueEntry.html#3a2ccdcdcac760623833136b5ced2410>fNext 
>== 
><http://www.live555.com/liveMedia/doxygen/html/UsageEnvironment_8hh.html#070d2ce7b6bb7e5c05602aa8c308d0c4>NULL) 
>return;
>
>+ if (entry == 
><http://www.live555.com/liveMedia/doxygen/html/UsageEnvironment_8hh.html#070d2ce7b6bb7e5c05602aa8c308d0c4>NULL 
>|| 
>entry-><http://www.live555.com/liveMedia/doxygen/html/classDelayQueueEntry.html#3a2ccdcdcac760623833136b5ced2410>fNext 
>== 
><http://www.live555.com/liveMedia/doxygen/html/UsageEnvironment_8hh.html#070d2ce7b6bb7e5c05602aa8c308d0c4>NULL 
>|| 
>entry-><http://www.live555.com/liveMedia/doxygen/html/classDelayQueueEntry.html#3a2ccdcdcac760623833136b5ced2410>fPrev 
>== 
><http://www.live555.com/liveMedia/doxygen/html/UsageEnvironment_8hh.html#070d2ce7b6bb7e5c05602aa8c308d0c4>NULL) 
>return;

In principle, this shouldn't be necessary, as it should never be the 
case that "entry->fNext" is non-NULL, but "entry->fPrev" is NULL.

So, I don't understand how your error could have occurred.  I hope 
you're not doing something dumb like trying to access a queue from 
multiple threads?

Puzzling...
-- 

Ross Finlayson
Live Networks, Inc.
http://www.live555.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.live555.com/pipermail/live-devel/attachments/20080612/1cc0c5df/attachment.html>


More information about the live-devel mailing list