summaryrefslogtreecommitdiff
path: root/device.c
diff options
context:
space:
mode:
Diffstat (limited to 'device.c')
-rw-r--r--device.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/device.c b/device.c
index 84caf4e1..b84b5a26 100644
--- a/device.c
+++ b/device.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: device.c 3.7 2014/01/02 10:31:58 kls Exp $
+ * $Id: device.c 3.8 2014/01/14 11:58:49 kls Exp $
*/
#include "device.h"
@@ -358,6 +358,7 @@ bool cDevice::HasCi(void)
void cDevice::SetCamSlot(cCamSlot *CamSlot)
{
+ LOCK_THREAD;
camSlot = CamSlot;
}
@@ -1575,6 +1576,7 @@ void cDevice::Action(void)
while (Running()) {
// Read data from the DVR device:
uchar *b = NULL;
+ LOCK_THREAD;
if (GetTSPacket(b)) {
if (b) {
int Pid = TsPid(b);
@@ -1599,7 +1601,6 @@ void cDevice::Action(void)
}
}
// Distribute the packet to all attached receivers:
- Lock();
for (int i = 0; i < MAXRECEIVERS; i++) {
if (receiver[i] && receiver[i]->WantsPid(Pid)) {
if (DetachReceivers) {
@@ -1612,7 +1613,6 @@ void cDevice::Action(void)
ChannelCamRelations.SetDecrypt(receiver[i]->ChannelID(), CamSlotNumber);
}
}
- Unlock();
}
}
else