mirror of
https://projects.vdr-developer.org/git/vdr-plugin-streamdev.git
synced 2023-10-10 19:16:51 +02:00
No need for Detach/Attach in SwitchDevice as it is only called when detached.
This commit is contained in:
parent
3e9e7f7de6
commit
5a173b0b21
@ -635,13 +635,8 @@ bool cStreamdevLiveStreamer::UsedByLiveTV(cDevice *device)
|
|||||||
|
|
||||||
cDevice *cStreamdevLiveStreamer::SwitchDevice(const cChannel *Channel, int Priority)
|
cDevice *cStreamdevLiveStreamer::SwitchDevice(const cChannel *Channel, int Priority)
|
||||||
{
|
{
|
||||||
// turn off the streams of this connection
|
|
||||||
Detach();
|
|
||||||
|
|
||||||
cDevice *device = cDevice::GetDevice(Channel, Priority, false);
|
cDevice *device = cDevice::GetDevice(Channel, Priority, false);
|
||||||
if (!device) {
|
if (!device) {
|
||||||
// can't switch - continue the current stream
|
|
||||||
Attach();
|
|
||||||
dsyslog("streamdev: GetDevice failed for channel %d (%s) at priority %d (PrimaryDevice=%d, ActualDevice=%d)", Channel->Number(), Channel->Name(), Priority, cDevice::PrimaryDevice()->CardIndex(), cDevice::ActualDevice()->CardIndex());
|
dsyslog("streamdev: GetDevice failed for channel %d (%s) at priority %d (PrimaryDevice=%d, ActualDevice=%d)", Channel->Number(), Channel->Name(), Priority, cDevice::PrimaryDevice()->CardIndex(), cDevice::ActualDevice()->CardIndex());
|
||||||
}
|
}
|
||||||
else if (!device->IsTunedToTransponder(Channel) && UsedByLiveTV(device)) {
|
else if (!device->IsTunedToTransponder(Channel) && UsedByLiveTV(device)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user