[vlc-commits] OSS access: don't choke on EINTR
Rémi Denis-Courmont
git at videolan.org
Sun Jan 23 17:02:34 CET 2011
vlc/vlc-1.1 | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Jan 23 17:36:15 2011 +0200| [719bc6ed47e8998c2a8f294643426dab6a57f3e9] | committer: Rémi Denis-Courmont
OSS access: don't choke on EINTR
(cherry picked from commit 0169865b68c30b1505beae2489f8f08e9619a337)
> http://git.videolan.org/gitweb.cgi/vlc/vlc-1.1.git/?a=commit;h=719bc6ed47e8998c2a8f294643426dab6a57f3e9
---
modules/access/oss.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/modules/access/oss.c b/modules/access/oss.c
index 60af003..d32c6e6 100644
--- a/modules/access/oss.c
+++ b/modules/access/oss.c
@@ -38,6 +38,7 @@
#include <vlc_demux.h>
#include <vlc_fs.h>
+#include <errno.h>
#include <fcntl.h>
#include <unistd.h>
#include <sys/ioctl.h>
@@ -272,6 +273,8 @@ static int Demux( demux_t *p_demux )
/* Wait for data */
if( poll( &fd, 1, 10 ) ) /* Timeout after 0.01 seconds. Bigger delays are an issue when used with/as an input-slave since all the inputs run in the same thread. */
{
+ if( errno == EINTR )
+ continue;
if( fd.revents & (POLLIN|POLLPRI) )
{
p_block = GrabAudio( p_demux );
More information about the vlc-commits
mailing list