From 008b1f47941e6479e5db106653232fb886196238 Mon Sep 17 00:00:00 2001 From: Damiano Galassi Date: Mon, 9 Jan 2017 09:18:03 +0100 Subject: libhb: check if decvobsub.c private_data is not null before accessing one of its member. Fix a crash when calling decsubClose if the decoder had not been initialized yet. --- libhb/decvobsub.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libhb/decvobsub.c') diff --git a/libhb/decvobsub.c b/libhb/decvobsub.c index 73401b9f3..009c12e96 100644 --- a/libhb/decvobsub.c +++ b/libhb/decvobsub.c @@ -196,7 +196,7 @@ void decsubClose( hb_work_object_t * w ) { hb_work_private_t * pv = w->private_data; - if ( pv->buf ) + if ( pv && pv->buf ) hb_buffer_close( &pv->buf ); free( w->private_data ); } -- cgit v1.2.3