Fix crash in uninit.
authorStefano Sabatini <stefano.sabatini-lala@poste.it>
Thu, 25 Nov 2010 23:51:37 +0000 (23:51 +0000)
committerStefano Sabatini <stefano.sabatini-lala@poste.it>
Thu, 25 Nov 2010 23:51:37 +0000 (23:51 +0000)
Originally committed as revision 25829 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavfilter/vf_frei0r.c

index 49fe172..48f5b49 100644 (file)
@@ -275,7 +275,7 @@ static av_cold void uninit(AVFilterContext *ctx)
 {
     Frei0rContext *frei0r = ctx->priv;
 
-    if (frei0r->destruct)
+    if (frei0r->destruct && frei0r->instance)
         frei0r->destruct(frei0r->instance);
     if (frei0r->deinit)
         frei0r->deinit();