History

Fix memleak due to c->decomp_buf never being freed.

Originally committed as revision 19064 to svn://svn.ffmpeg.org/ffmpeg/trunk

Reimar Döffinger committed 17 years ago

Commit bbf30671 parent 908425c1 file · +2 −0Browse files

Unified · Split

libavcodec/lcldec.c+2−0
@@ -573,6 +573,7 @@ static av_cold int decode_init(AVCodecContext *avctx) · 572 unmodified lines
573 zret = inflateInit(&c->zstream);573 zret = inflateInit(&c->zstream);
574 if (zret != Z_OK) {574 if (zret != Z_OK) {
575 av_log(avctx, AV_LOG_ERROR, "Inflate init error: %d\n", zret);575 av_log(avctx, AV_LOG_ERROR, "Inflate init error: %d\n", zret);
576 av_freep(&c->decomp_buf);
576 return 1;577 return 1;
577 }578 }
578 }579 }
@@ -590,6 +591,7 @@ static av_cold int decode_end(AVCodecContext *avctx) · 11 unmodified lines
590{591{
591 LclDecContext * const c = avctx->priv_data;592 LclDecContext * const c = avctx->priv_data;
592 593
594 av_freep(&c->decomp_buf);
593 if (c->pic.data[0])595 if (c->pic.data[0])
594 avctx->release_buffer(avctx, &c->pic);596 avctx->release_buffer(avctx, &c->pic);
595#if CONFIG_ZLIB_DECODER597#if CONFIG_ZLIB_DECODER

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t