diff options
author | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2009-02-15 13:17:04 +0000 |
---|---|---|
committer | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2009-02-15 13:17:04 +0000 |
commit | 9275737b40b434e9c043c73f745f774c9c055c42 (patch) | |
tree | 02093ce225bcfabb5a80c16828dcecd6856d456a /libmpcodecs | |
parent | eee0fbd3afbb0748f6446f9d9876c7a8611b1ad8 (diff) |
Merge two checks for mpi != NULL
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28589 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpcodecs')
-rw-r--r-- | libmpcodecs/vd_ffmpeg.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libmpcodecs/vd_ffmpeg.c b/libmpcodecs/vd_ffmpeg.c index 5b0dc97ad1..d91c9dab61 100644 --- a/libmpcodecs/vd_ffmpeg.c +++ b/libmpcodecs/vd_ffmpeg.c @@ -653,11 +653,11 @@ static void release_buffer(struct AVCodecContext *avctx, AVFrame *pic){ ctx->b_count--; } - // Palette support: free palette buffer allocated in get_buffer - if (mpi && (mpi->bpp == 8)) - av_freep(&mpi->planes[1]); -#if CONFIG_XVMC if (mpi) { + // Palette support: free palette buffer allocated in get_buffer + if (mpi->bpp == 8) + av_freep(&mpi->planes[1]); +#if CONFIG_XVMC if (IMGFMT_IS_XVMC(mpi->imgfmt)) { struct xvmc_pixfmt_render *render = (struct xvmc_pixfmt_render *)pic->data[2];//same as mpi->priv if(mp_msg_test(MSGT_DECVIDEO, MSGL_DBG5)) @@ -666,8 +666,8 @@ static void release_buffer(struct AVCodecContext *avctx, AVFrame *pic){ assert(render->magic_id==AV_XVMC_RENDER_MAGIC); render->state&=~AV_XVMC_STATE_PREDICTION; } - } #endif + } if(pic->type!=FF_BUFFER_TYPE_USER){ avcodec_default_release_buffer(avctx, pic); |