OSDN Git Service
(root)
/
android-x86
/
external-ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8fe5924
)
libxvid: check & clear encoder_handle
author
Michael Niedermayer
<michaelni@gmx.at>
Sat, 2 Mar 2013 19:32:21 +0000
(20:32 +0100)
committer
Michael Niedermayer
<michaelni@gmx.at>
Sat, 2 Mar 2013 19:32:21 +0000
(20:32 +0100)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/libxvid.c
patch
|
blob
|
history
diff --git
a/libavcodec/libxvid.c
b/libavcodec/libxvid.c
index
9c86e3c
..
fac2e8c
100644
(file)
--- a/
libavcodec/libxvid.c
+++ b/
libavcodec/libxvid.c
@@
-735,7
+735,9
@@
static int xvid_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
static av_cold int xvid_encode_close(AVCodecContext *avctx) {
struct xvid_context *x = avctx->priv_data;
- xvid_encore(x->encoder_handle, XVID_ENC_DESTROY, NULL, NULL);
+ if(x->encoder_handle)
+ xvid_encore(x->encoder_handle, XVID_ENC_DESTROY, NULL, NULL);
+ x->encoder_handle = NULL;
av_freep(&avctx->extradata);
if( x->twopassbuffer != NULL ) {