[vlc-devel] [PATCH 06/10] Make record stream filter forward pf_readdir calls

Julien 'Lta' BALLET elthariel at gmail.com
Mon Jun 16 14:41:08 CEST 2014


From: Julien 'Lta' BALLET <contact at lta.io>

---
 modules/stream_filter/record.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/modules/stream_filter/record.c b/modules/stream_filter/record.c
index 538d506..89d2842 100644
--- a/modules/stream_filter/record.c
+++ b/modules/stream_filter/record.c
@@ -67,6 +67,7 @@ struct stream_sys_t
 static int  Read   ( stream_t *, void *p_read, unsigned int i_read );
 static int  Peek   ( stream_t *, const uint8_t **pp_peek, unsigned int i_peek );
 static int  Control( stream_t *, int i_query, va_list );
+static input_item_t *ReadDir( stream_t * );
 
 static int  Start  ( stream_t *, const char *psz_extension );
 static int  Stop   ( stream_t * );
@@ -91,6 +92,7 @@ static int Open ( vlc_object_t *p_this )
     s->pf_read = Read;
     s->pf_peek = Peek;
     s->pf_control = Control;
+    s->pf_readdir = ReadDir;
 
     return VLC_SUCCESS;
 }
@@ -241,3 +243,11 @@ static void Write( stream_t *s, const uint8_t *p_buffer, size_t i_buffer )
             msg_Err( s, "Failed to record data (end)" );
     }
 }
+
+input_item_t *ReadDir( stream_t *s )
+{
+    if( s != NULL )
+        return stream_ReadDir( s->p_source );
+    else
+        return NULL;
+}
-- 
1.9.3




More information about the vlc-devel mailing list