[vlc-commits] sout record: do not set ops on error

Rémi Denis-Courmont git at videolan.org
Sat Oct 10 18:40:17 CEST 2020


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Oct 10 19:38:11 2020 +0300| [fb01b2bb9e9a333516b7e2c54af51f9052ff5e50] | committer: Rémi Denis-Courmont

sout record: do not set ops on error

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

 modules/stream_out/record.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/modules/stream_out/record.c b/modules/stream_out/record.c
index 1f8560302c..eb3e16c41c 100644
--- a/modules/stream_out/record.c
+++ b/modules/stream_out/record.c
@@ -126,8 +126,6 @@ static int Open( vlc_object_t *p_this )
     sout_stream_t *p_stream = (sout_stream_t*)p_this;
     sout_stream_sys_t *p_sys;
 
-    p_stream->ops = &ops;
-
     p_stream->p_sys = p_sys = malloc( sizeof(*p_sys) );
     if( !p_sys )
         return VLC_ENOMEM;
@@ -158,6 +156,7 @@ static int Open( vlc_object_t *p_this )
     p_sys->b_drop = false;
     p_sys->i_dts_start = 0;
     TAB_INIT( p_sys->i_id, p_sys->id );
+    p_stream->ops = &ops;
 
     return VLC_SUCCESS;
 }



More information about the vlc-commits mailing list