mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-31 09:21:18 +02:00
eitd/dmx.cpp: revert dmx Open/Close to use Stop - prevent crash,
if one thread use change() while other try to read (time thread)
This commit is contained in:
@@ -42,7 +42,7 @@
|
|||||||
#include "dmx.h"
|
#include "dmx.h"
|
||||||
#include "debug.h"
|
#include "debug.h"
|
||||||
|
|
||||||
#define DEBUG_MUTEX 1
|
//#define DEBUG_MUTEX 1
|
||||||
//#define DEBUG_DEMUX 1 // debug start/close/change
|
//#define DEBUG_DEMUX 1 // debug start/close/change
|
||||||
//#define DEBUG_CACHED_SECTIONS 1
|
//#define DEBUG_CACHED_SECTIONS 1
|
||||||
//#define DEBUG_COMPLETE_SECTIONS 1
|
//#define DEBUG_COMPLETE_SECTIONS 1
|
||||||
@@ -120,7 +120,7 @@ void DMX::closefd(void)
|
|||||||
#endif
|
#endif
|
||||||
if (isOpen())
|
if (isOpen())
|
||||||
{
|
{
|
||||||
dmx->Close();
|
dmx->Stop();
|
||||||
fd = -1;
|
fd = -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -484,8 +484,8 @@ int DMX::immediate_start(void)
|
|||||||
|
|
||||||
if(dmx == NULL) {
|
if(dmx == NULL) {
|
||||||
dmx = new cDemux(dmx_num);
|
dmx = new cDemux(dmx_num);
|
||||||
|
dmx->Open(DMX_PSI_CHANNEL, NULL, dmxBufferSizeInKB*1024UL);
|
||||||
}
|
}
|
||||||
dmx->Open(DMX_PSI_CHANNEL, NULL, dmxBufferSizeInKB*1024UL);
|
|
||||||
fd = 1;
|
fd = 1;
|
||||||
|
|
||||||
/* setfilter() only if this is no dummy filter... */
|
/* setfilter() only if this is no dummy filter... */
|
||||||
|
Reference in New Issue
Block a user