[Live-devel] Appropriate way to shutdown task scheduler and usage environment.

Dario dmaljur at elma.hr
Mon Nov 16 02:39:53 PST 2009


I wrote a video client that at one point needs to shut down all incoming mpeg4 streams and delete usage environent 
and task scheduler. 
After that it needs to allocate new set of RTSPClient and start streaming all over again.

The only way I managed to get task scheduler to work after the first set of streams is shut downed is
by deleting the task scheduler and usage environent. For some reason if I don't create new task scheduler and env
the loop gets stuck and no frames are streaming.

But now there is a problem where I use: 

  usageEnvironment->reclaim();
  delete scheduler;
  scheduler = NULL;

  scheduler = BasicTaskScheduler::createNew();
  usageEnvironent = BasicUsageEnvironment::createNew(*scheduler);

after starting event loop there's a 12kb leak which is not dealocated with reclaim.
So I guess I did something wrong here. Can someone point me where?

Also, why can't I use the same task scheduler after I shutdowned all active streams?

Thanks.


 


ELMA Kurtalj d.o.o. (ELMA Kurtalj ltd.)
Vitezićeva 1a, 10000 Zagreb, Hrvatska (Viteziceva 1a, 10000 Zagreb, Croatia)
Tel: 01/3035555, Faks: 01/3035599 (Tel: ++385-1-3035555, Fax: ++385-1-3035599 )

Www:
www.elma.hr; shop.elma.hr

E-mail:
elma at elma.hr (elma at elma.hr)
pitanje at elma.hr (questions at elma.hr)
primjedbe at elma.hr (complaints at elma.hr)
prodaja at elma.hr (sales at elma.hr)
servis at elma.hr (servicing at elma.hr)
shop at elma.hr (shop at elma.hr)
skladiste at elma.hr (warehouse at elma.hr)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.live555.com/pipermail/live-devel/attachments/20091116/cecc733d/attachment.html>


More information about the live-devel mailing list