OSDN Git Service
(root)
/
coroid
/
libav_saccubus.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7c4a001
)
Add a NULL pointer check to avcodec_close() this should prevent a segfault
author
Michael Niedermayer
<michaelni@gmx.at>
Tue, 10 Nov 2009 02:51:47 +0000
(
02:51
+0000)
committer
Michael Niedermayer
<michaelni@gmx.at>
Tue, 10 Nov 2009 02:51:47 +0000
(
02:51
+0000)
when closing without open.
Originally committed as revision 20495 to svn://svn.ffmpeg.org/ffmpeg/trunk
libavcodec/utils.c
patch
|
blob
|
history
diff --git
a/libavcodec/utils.c
b/libavcodec/utils.c
index
2f18848
..
ddd1160
100644
(file)
--- a/
libavcodec/utils.c
+++ b/
libavcodec/utils.c
@@
-675,7
+675,7
@@
int avcodec_close(AVCodecContext *avctx)
if (HAVE_THREADS && avctx->thread_opaque)
avcodec_thread_free(avctx);
- if (avctx->codec->close)
+ if (avctx->codec
&& avctx->codec
->close)
avctx->codec->close(avctx);
avcodec_default_free_buffers(avctx);
av_freep(&avctx->priv_data);