]> git.sesse.net Git - vlc/commitdiff
avcodec: fix potential multiple free of hwaccel module
authorRémi Denis-Courmont <remi@remlab.net>
Fri, 19 Jul 2013 15:54:49 +0000 (18:54 +0300)
committerRémi Denis-Courmont <remi@remlab.net>
Fri, 19 Jul 2013 15:54:49 +0000 (18:54 +0300)
modules/codec/avcodec/video.c

index f4421ac37ac2d136d8aced6379d1e06c42bd72b4..c6e6fed2fdca2d21af9015165fc1e927077328af 100644 (file)
@@ -1175,9 +1175,8 @@ static enum PixelFormat ffmpeg_GetFormat( AVCodecContext *p_context,
     msg_Err( p_dec, "acceleration not available" );
     vlc_va_Delete( p_va );
 
-    p_sys->p_va = NULL;
-
 end:
     /* Fallback to default behaviour */
+    p_sys->p_va = NULL;
     return avcodec_default_get_format( p_context, pi_fmt );
 }