summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDamiano Galassi <[email protected]>2017-12-16 09:49:38 +0100
committerDamiano Galassi <[email protected]>2017-12-16 09:49:38 +0100
commit60826581e324cb8fa7ea9d99b1f3327bdd4b1df9 (patch)
tree91672e2647c4f17e11c1d1ffdf96a6f5e8f813c9
parent573b5ab5dc9fe6d6ec3b8e97620df8c713964a0e (diff)
theora: fix a crash when enctheoraClose is called and pv is NULL.
-rw-r--r--libhb/enctheora.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libhb/enctheora.c b/libhb/enctheora.c
index 390b52177..00b4d18eb 100644
--- a/libhb/enctheora.c
+++ b/libhb/enctheora.c
@@ -190,6 +190,11 @@ void enctheoraClose( hb_work_object_t * w )
{
hb_work_private_t * pv = w->private_data;
+ if (pv == NULL)
+ {
+ return;
+ }
+
th_encode_free( pv->ctx );
if( pv->file )