[Live-devel] Remove a session...
Raphael KINDT
raphael.kindt at seldes.com
Mon Apr 14 01:24:19 PDT 2008
Hello,
I try to remove a server media session dynamically but sometimes my
application crash.
This crash seems to be localized in the task scheduler.
Here is my remove session function:
bool RemoveSession(const std::string & _session_name)
{
sessionMap[_session_name].sink->stopPlaying();
sessionMap[_session_name].source->stopGettingFrames();
rtspServer->removeServerMediaSession(sessionMap[_session_name].sms);
Medium::close(sessionMap[_session_name].sink);
Medium::close(sessionMap[_session_name].source);
Medium::close(sessionMap[_session_name].rtcpInstance);
delete sessionMap[_session_name].rtpGroupsock;
delete sessionMap[_session_name].rtcpGroupsock;
return true;
}
Is that a good instructions sequence?
Do you found errors?
Thanks in advance for your help.
Raphael
-----Message d'origine-----
De : live-devel-bounces at ns.live555.com
[mailto:live-devel-bounces at ns.live555.com]De la part de Ross Finlayson
Envoye : samedi 12 avril 2008 5:23
A : LIVE555 Streaming Media - development & use
Objet : Re: [Live-devel] Remove a session...
>What are the situations where DynamicRTSPServer is usefull to use?
From the header file: "DynamicRTSPServer" is
// A subclass of "RTSPServer" that creates "ServerMediaSession"s on demand,
// based on whether or not the specified stream name exists as a file
I.e., instead of creating, in advance, a set of "ServerMediaSession"s
for a particular set of files (as is done in the
"testOnDemandRTSPServer" demo application, for example), a
"DynamicRTSPServer" creates a "ServerMediaSession" for a file only
when that file is specifically requested to be streamed (by a RTSP
client).
>How to wake up env->taskScheduler().doEventLoop(&watch_scheduler) when
>no server media session is added?
>The loop is waiting at a 'select()' call and thus doesn't check my
>watch_scheduler.
I'm not totally sure I udnerstand the question, but I suspect it's
related to this point:
http://lists.live555.com/pipermail/live-devel/2006-March/004192.html
--
Ross Finlayson
Live Networks, Inc.
http://www.live555.com/
_______________________________________________
live-devel mailing list
live-devel at lists.live555.com
http://lists.live555.com/mailman/listinfo/live-devel
More information about the live-devel
mailing list