aboutsummaryrefslogtreecommitdiff
path: root/multimedia/vdr-plugin-reelchannelscan/files/patch-scan.c
diff options
context:
space:
mode:
Diffstat (limited to 'multimedia/vdr-plugin-reelchannelscan/files/patch-scan.c')
-rw-r--r--multimedia/vdr-plugin-reelchannelscan/files/patch-scan.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/multimedia/vdr-plugin-reelchannelscan/files/patch-scan.c b/multimedia/vdr-plugin-reelchannelscan/files/patch-scan.c
index 70f6d1566ad0..024cb81c40b9 100644
--- a/multimedia/vdr-plugin-reelchannelscan/files/patch-scan.c
+++ b/multimedia/vdr-plugin-reelchannelscan/files/patch-scan.c
@@ -1,15 +1,25 @@
--- a/scan.c
+++ b/scan.c
-@@ -197,7 +197,7 @@ bool cScan::StartScanning(cScanParameter
+@@ -197,7 +197,17 @@ bool cScan::StartScanning(cScanParameter
#ifndef DEVICE_ATTRIBUTES
char buffer[265];
- snprintf(buffer, sizeof(buffer), "/dev/dvb/adapter%d/frontend0", cardnr);
++#if APIVERSNUM > 10723
++ int Adapter = -1, Frontend = -1;
++ if (!cPluginChannelscan::GetAdapterFrontend(cDevice::GetDevice(cardnr)->CardIndex(), Adapter, Frontend)) {
++ esyslog("GetAdapterFrontend() failed");
++ cMenuChannelscan::scanState = ssDeviceFailure;
++ return false;
++ }
++ snprintf(buffer, sizeof(buffer), "/dev/dvb/adapter%d/frontend%d", Adapter, Frontend);
++#else
+ snprintf(buffer, sizeof(buffer), "/dev/dvb/adapter%d/frontend0", cDevice::GetDevice(cardnr)->CardIndex());
++#endif
fd_frontend = open(buffer, O_RDONLY | O_NONBLOCK);
if (fd_frontend <= 0) {
-@@ -932,12 +932,12 @@ void cScan::Action()
+@@ -932,12 +942,12 @@ void cScan::Action()
char *strDate;
asprintf(&strDate,"%s", asctime(localtime(&tt)));
strDate[strlen(strDate)-1] = 0;