History

avcodec/vp9_superframe_bsf: cache packets by creating new references rather than moving them

Should hopefully fix the invalid reads after free introduced in e1bc3f4396ade6033787717d3650fb62663eae8 for all targets.

James Almer committed 9 years ago

Commit 7a02b361 parent 05d77581 file · +3 −1Browse files

Unified · Split

libavcodec/vp9_superframe_bsf.c+3−1
@@ -147,7 +147,9 @@ static int vp9_superframe_filter(AVBSFContext *ctx, AVPacket *out) · 146 unmodified lines
147147 goto done;
148148 }
149149
150− av_packet_move_ref(s->cache[s->n_cache++], in);
150+ res = av_packet_ref(s->cache[s->n_cache++], in);
151+ if (res < 0)
152+ goto done;
151153
152154 if (invisible) {
153155 res = AVERROR(EAGAIN);

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