changeset 6069:3670c9e7ff4d libavcodec

Check for avcodec_open codec parameter == NULL and return error in that case
author reimar
date Tue, 25 Dec 2007 15:36:12 +0000
parents 333b8024c6b2
children 4acd7b248bb8
files utils.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/utils.c	Sun Dec 23 21:01:09 2007 +0000
+++ b/utils.c	Tue Dec 25 15:36:12 2007 +0000
@@ -848,7 +848,7 @@
         goto end;
     }
 
-    if(avctx->codec)
+    if(avctx->codec || !codec)
         goto end;
 
     if (codec->priv_data_size > 0) {