summaryrefslogtreecommitdiff
path: root/dxr3interface.c
diff options
context:
space:
mode:
authorChristian Gmeiner <christian.gmeiner@gmail.com>2009-10-15 11:04:19 +0200
committerChristian Gmeiner <christian.gmeiner@gmail.com>2009-10-15 11:04:19 +0200
commit1b9e3804075c2dc6f70beb2e9d14ecbb6f23710c (patch)
tree4826c1147e287dd0a66fcc6625b020bf28bb126c /dxr3interface.c
parent79956361579c8474684b2bd6509f282eb81425c5 (diff)
downloadvdr-plugin-dxr3-1b9e3804075c2dc6f70beb2e9d14ecbb6f23710c.tar.gz
vdr-plugin-dxr3-1b9e3804075c2dc6f70beb2e9d14ecbb6f23710c.tar.bz2
check return value of ioctl syscalls
Diffstat (limited to 'dxr3interface.c')
-rw-r--r--dxr3interface.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/dxr3interface.c b/dxr3interface.c
index e3d3cea..ea752f6 100644
--- a/dxr3interface.c
+++ b/dxr3interface.c
@@ -72,7 +72,7 @@ void cDxr3Interface::SetSysClock(uint32_t scr)
uint32_t sc;
Lock();
- ioctl(m_fdControl, EM8300_IOCTL_SCR_GET, &sc);
+ CHECK(ioctl(m_fdControl, EM8300_IOCTL_SCR_GET, &sc));
m_offset = scr - sc;
Unlock();
}
@@ -84,7 +84,7 @@ uint32_t cDxr3Interface::GetSysClock()
uint32_t retval;
Lock();
- ioctl(m_fdControl, EM8300_IOCTL_SCR_GET, &sc);
+ CHECK(ioctl(m_fdControl, EM8300_IOCTL_SCR_GET, &sc));
retval = sc + m_offset;
Unlock();
@@ -98,7 +98,7 @@ void cDxr3Interface::SetPts(uint32_t pts)
Lock();
newPts = pts - m_offset;
- ioctl(m_fdVideo, EM8300_IOCTL_VIDEO_SETPTS, &newPts);
+ CHECK(ioctl(m_fdVideo, EM8300_IOCTL_VIDEO_SETPTS, &newPts));
Unlock();
}
@@ -109,7 +109,7 @@ void cDxr3Interface::SetSpuPts(uint32_t pts)
Lock();
newPts = (pts - m_offset) << 1; // fix for DVD subtitles
- ioctl(m_fdSpu, EM8300_IOCTL_SPU_SETPTS, &newPts);
+ CHECK(ioctl(m_fdSpu, EM8300_IOCTL_SPU_SETPTS, &newPts));
Unlock();
}
@@ -679,7 +679,7 @@ void cDxr3Interface::SetButton(uint16_t sx, uint16_t sy, uint16_t ex,
button.left = sx;
button.right = ex;
- ioctl(m_fdSpu, EM8300_IOCTL_SPU_BUTTON, &button);
+ CHECK(ioctl(m_fdSpu, EM8300_IOCTL_SPU_BUTTON, &button));
}
// ==================================
@@ -694,13 +694,13 @@ void cDxr3Interface::ClearButton()
button.left = 1;
button.right = 2;
- ioctl(m_fdSpu, EM8300_IOCTL_SPU_BUTTON, &button);
+ CHECK(ioctl(m_fdSpu, EM8300_IOCTL_SPU_BUTTON, &button));
}
// ==================================
void cDxr3Interface::SetPalette(unsigned int *pal)
{
- ioctl(m_fdSpu, EM8300_IOCTL_SPU_SETPALETTE, (uint8_t*)pal);
+ CHECK(ioctl(m_fdSpu, EM8300_IOCTL_SPU_SETPALETTE, (uint8_t*)pal));
}
// helper functions for dxr3 main osd screen