git.cweiske.de
/
enigma2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
remove unneeded
[enigma2.git]
/
lib
/
dvb
/
demux.cpp
diff --git
a/lib/dvb/demux.cpp
b/lib/dvb/demux.cpp
index d2a2a545dc27a9f34c6ca66284c9a76b756bd815..78c55bfebf744fde59253d3b8d73b8f9e76e32a6 100644
(file)
--- a/
lib/dvb/demux.cpp
+++ b/
lib/dvb/demux.cpp
@@
-6,7
+6,6
@@
#include <unistd.h>
#include <signal.h>
#include <unistd.h>
#include <signal.h>
-
#if HAVE_DVB_API_VERSION < 3
#include <ost/dmx.h>
#ifndef DMX_SET_NEGFILTER_MASK
#if HAVE_DVB_API_VERSION < 3
#include <ost/dmx.h>
#ifndef DMX_SET_NEGFILTER_MASK
@@
-49,18
+48,29
@@
DEFINE_REF(eDVBDemux)
RESULT eDVBDemux::setSourceFrontend(int fenum)
{
RESULT eDVBDemux::setSourceFrontend(int fenum)
{
+#if HAVE_DVB_API_VERSION >= 3
int fd = openDemux();
int fd = openDemux();
- int res = ::ioctl(fd, DMX_SET_SOURCE, DMX_SOURCE_FRONT0 + fenum);
+
+ int n = DMX_SOURCE_FRONT0 + fenum;
+ int res = ::ioctl(fd, DMX_SET_SOURCE, &n);
+ if (res)
+ eDebug("DMX_SET_SOURCE failed! - %m");
::close(fd);
return res;
::close(fd);
return res;
+#endif
+ return 0;
}
RESULT eDVBDemux::setSourcePVR(int pvrnum)
{
}
RESULT eDVBDemux::setSourcePVR(int pvrnum)
{
+#if HAVE_DVB_API_VERSION >= 3
int fd = openDemux();
int fd = openDemux();
- int res = ::ioctl(fd, DMX_SET_SOURCE, DMX_SOURCE_DVR0 + pvrnum);
+ int n = DMX_SOURCE_DVR0 + pvrnum;
+ int res = ::ioctl(fd, DMX_SET_SOURCE, &n);
::close(fd);
return res;
::close(fd);
return res;
+#endif
+ return 0;
}
RESULT eDVBDemux::createSectionReader(eMainloop *context, ePtr<iDVBSectionReader> &reader)
}
RESULT eDVBDemux::createSectionReader(eMainloop *context, ePtr<iDVBSectionReader> &reader)
@@
-86,7
+96,7
@@
RESULT eDVBDemux::getMPEGDecoder(ePtr<iTSMPEGDecoder> &decoder)
return 0;
}
return 0;
}
-RESULT eDVBDemux::getSTC(pts_t &pts)
+RESULT eDVBDemux::getSTC(pts_t &pts
, int num
)
{
int fd = openDemux();
{
int fd = openDemux();
@@
-94,7
+104,7
@@
RESULT eDVBDemux::getSTC(pts_t &pts)
return -ENODEV;
struct dmx_stc stc;
return -ENODEV;
struct dmx_stc stc;
- stc.num =
0
;
+ stc.num =
num
;
stc.base = 1;
if (ioctl(fd, DMX_GET_STC, &stc) < 0)
stc.base = 1;
if (ioctl(fd, DMX_GET_STC, &stc) < 0)