]> git.sesse.net Git - vlc/blobdiff - modules/access_filter/timeshift.c
Don't print a message a malloc failed.
[vlc] / modules / access_filter / timeshift.c
index da4284e4d9e528108a8f22cae90963e841d383e4..b01cc1c649e54e8e7e1b661edec8e9a2e57a1ec9 100644 (file)
@@ -29,7 +29,7 @@
 # include "config.h"
 #endif
 
-#include <vlc/vlc.h>
+#include <vlc_common.h>
 #include <vlc_plugin.h>
 
 #include <errno.h>
@@ -275,7 +275,7 @@ static void Thread( access_t *p_access )
     access_t     *p_src = p_access->p_source;
     block_t      *p_block;
 
-    while( !p_access->b_die )
+    while( vlc_object_alive (p_access) )
     {
         /* Get a new block from the source */
         if( p_src->pf_block )
@@ -320,7 +320,7 @@ static void Thread( access_t *p_access )
 
         /* Read from file to fill up the fifo */
         while( block_FifoSize( p_sys->p_fifo ) < TIMESHIFT_FIFO_MIN &&
-               !p_access->b_die )
+               vlc_object_alive (p_access) )
         {
             p_block = ReadBlockFromFile( p_access );
             if( !p_block ) break;
@@ -331,12 +331,12 @@ static void Thread( access_t *p_access )
 
     msg_Dbg( p_access, "timeshift: no more input data" );
 
-    while( !p_access->b_die &&
+    while( vlc_object_alive (p_access) &&
            (p_sys->p_read_list || block_FifoSize( p_sys->p_fifo ) ) )
     {
         /* Read from file to fill up the fifo */
         while( block_FifoSize( p_sys->p_fifo ) < TIMESHIFT_FIFO_MIN &&
-               !p_access->b_die && p_sys->p_read_list )
+               vlc_object_alive (p_access) && p_sys->p_read_list )
         {
             p_block = ReadBlockFromFile( p_access );
             if( !p_block ) break;