[vlc-commits] stream_extractor/archive: prevent null-pointer dereference
Filip Roséen
git at videolan.org
Fri Feb 24 00:22:56 CET 2017
vlc | branch: master | Filip Roséen <filip at atch.se> | Thu Feb 23 14:54:27 2017 +0100| [c3c3d670a11ab1fe8aebff16d878bd280abecdb8] | committer: Jean-Baptiste Kempf
stream_extractor/archive: prevent null-pointer dereference
Given that p_sys->p_obj is yet to be initialized with the value of the
obj, the implementation should use the latter (given that the former
will be zero-initialized, but nothing more).
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c3c3d670a11ab1fe8aebff16d878bd280abecdb8
---
modules/stream_extractor/archive.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/modules/stream_extractor/archive.c b/modules/stream_extractor/archive.c
index 3d34d8c..6849459 100644
--- a/modules/stream_extractor/archive.c
+++ b/modules/stream_extractor/archive.c
@@ -378,7 +378,7 @@ static int archive_seek_subentry( private_sys_t* p_sys, char const* psz_subentry
static private_sys_t* setup( vlc_object_t* obj, stream_t* source )
{
private_sys_t* p_sys = calloc( 1, sizeof( *p_sys ) );
- char* psz_files = var_InheritString( p_sys->p_obj, "concat-list" );
+ char* psz_files = var_InheritString( obj, "concat-list" );
if( unlikely( !p_sys ) )
goto error;
More information about the vlc-commits
mailing list