Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] Re: vdr-1.3.17: thread issues with vdr-xine and vdr-osdteletext



Klaus Schmidinger wrote:
C.Y.M wrote:

Klaus Schmidinger wrote:

...

OK, this has been a problem (even with the previous thread safe patches I was using), but when I try to use streamdev in suspend mode with Klaus' new threading patch, it appears that VDR is creating TWO threads.


Dec 19 12:33:07 poseidon vdr[26763]: switching to channel 10300
Dec 19 12:33:07 poseidon vdr[30554]: transfer thread started (pid=30554, tid=1900553)
Dec 19 12:33:07 poseidon vdr[30555]: transfer thread started (pid=30555, tid=1916938)
Dec 19 12:33:07 poseidon vdr[30556]: receiver on device 1 thread started (pid=30556, tid=1933323)
Dec 19 12:33:07 poseidon vdr[30557]: TS buffer on device 1 thread started (pid=30557, tid=1949708)
Dec 19 12:33:10 poseidon vdr[26779]: ERROR: thread 1933323 won't end (waited 3 seconds) - canceling it...
Dec 19 12:33:10 poseidon vdr[30555]: transfer thread ended (pid=30555, tid=1916938)
Dec 19 12:33:10 poseidon vdr[26779]: buffer stats: 0 (0%) used



That's odd. Does streamdev mess around with "Transfer Mode"?

I probably am not the right person to answer that question, but I know that if you manually tune vdr to a channel and then try to stream, it works fine. But, if I am on a different channel and use the suspend option to tell vdr to switch to the channel that I want it to stream, then there seems to be some kind of race condition that is causing two threads to be created. I wish I could offer you more details.

Thanks,
C.Y.M.

I know that there's still a possible race condition in cDevice::AttachReceiver().
You could try this (untested, just an idea):

Thanks for the try, but suspend mode in streamdev still fails with this additional patch for thread.c.

The situation is that I manually switch to chan 10302. Then with VLC I put in the network address of http://poseidon:3000/10300 and this is what happens.

Dec 19 14:30:04 poseidon vdr[7770]: buffer stats: 74448 (2%) used
Dec 19 14:31:36 poseidon vdr[7754]: switching to channel 10302
Dec 19 14:32:05 poseidon vdr[7770]: Streamdev: Accepted new client (HTTP) 10.1.1.66:1520
Dec 19 14:32:05 poseidon vdr[7813]: receiver on device 1 thread started (pid=7813, tid=393225)
Dec 19 14:32:05 poseidon vdr[7814]: TS buffer on device 1 thread started (pid=7814, tid=409610)
Dec 19 14:32:05 poseidon vdr[7754]: switching to channel 10302
Dec 19 14:32:08 poseidonr vdr[7770]: ERROR: thread 393225 won't end (waited 3 seconds) - canceling it...
Dec 19 14:32:08 poseidon vdr[7818]: receiver on device 1 thread started (pid=7818, tid=475145)
Dec 19 14:32:08 poseidon vdr[7819]: Streamdev: Live streamer thread started (pid=7819, tid=491531)
Dec 19 14:32:08 poseidon vdr[7814]: TS buffer on device 1 thread ended (pid=7814, tid=409610)
Dec 19 14:32:08 poseidon vdr[7818]: buffer stats: 0 (0%) used
Dec 19 14:32:08 poseidon vdr[7820]: TS buffer on device 1 thread started (pid=7820, tid=507914)
Dec 19 14:32:31 poseidon vdr[7770]: Streamdev: Read from client (HTTP) 10.1.1.66:1520 dbg: Connection reset by peer
Dec 19 14:32:31 poseidon vdr[7770]: Streamdev: Closing connection to 10.1.1.66:1520
Dec 19 14:32:31 poseidon vdr[7820]: TS buffer on device 1 thread ended (pid=7820, tid=507914)
Dec 19 14:32:31 poseidon vdr[7818]: buffer stats: 60160 (2%) used
Dec 19 14:32:31 poseidon vdr[7818]: receiver on device 1 thread ended (pid=7818, tid=475145)
Dec 19 14:32:31 poseidon vdr[7819]: Streamdev: Live streamer thread ended (pid=7819, tid=491531)
Dec 19 14:32:31 poseidon vdr[7770]: buffer stats: 60536 (1%) used





Home | Main Index | Thread Index