[vlc-commits] linsys_hdsdi: do not fail on EINTR

Rémi Denis-Courmont git at videolan.org
Thu Feb 5 21:41:00 CET 2015


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Feb  5 21:46:39 2015 +0200| [9dfa7a91e60909b3321d1f0f842c66b55ea83a08] | committer: Rémi Denis-Courmont

linsys_hdsdi: do not fail on EINTR

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=9dfa7a91e60909b3321d1f0f842c66b55ea83a08
---

 modules/access/linsys/linsys_hdsdi.c |   15 ++++-----------
 1 file changed, 4 insertions(+), 11 deletions(-)

diff --git a/modules/access/linsys/linsys_hdsdi.c b/modules/access/linsys/linsys_hdsdi.c
index 8ca6094..36d9a1a 100644
--- a/modules/access/linsys/linsys_hdsdi.c
+++ b/modules/access/linsys/linsys_hdsdi.c
@@ -675,12 +675,8 @@ static int InitCapture( demux_t *p_demux )
         pfd[0].fd = p_sys->i_vfd;
         pfd[0].events = POLLPRI;
 
-        if ( poll( pfd, 1, READ_TIMEOUT ) < 0 )
-        {
-            msg_Warn( p_demux, "couldn't poll(): %s", vlc_strerror_c(errno) );
-            close( p_sys->i_vfd );
-            return VLC_EGENERIC;
-        }
+        if( poll( pfd, 1, READ_TIMEOUT ) < 0 )
+           continue;
 
         if ( pfd[0].revents & POLLPRI )
         {
@@ -931,11 +927,8 @@ static int Capture( demux_t *p_demux )
         pfd[1].events = POLLIN | POLLPRI;
     }
 
-    if ( poll( pfd, 1 + (p_sys->i_max_channel != -1), READ_TIMEOUT ) < 0 )
-    {
-        msg_Warn( p_demux, "couldn't poll(): %s", vlc_strerror_c(errno) );
-        return VLC_EGENERIC;
-    }
+    if( poll( pfd, 1 + (p_sys->i_max_channel != -1), READ_TIMEOUT ) < 0 )
+        return VLC_SUCCESS;
 
     if ( pfd[0].revents & POLLPRI )
     {



More information about the vlc-commits mailing list