History

avcodec/vble: Don't free buffer known to be NULL

Freeing a buffer allocated in the VBLE decoder's init function is the only thing the decoder's close function does and this implies that it is unnecessary to call it in case said allocation fails. Yet this is what has been done.

Andreas Rheinhardt committed 6 years ago

Commit a265e661 parent b1283441 file · +0 −1Browse files

Unified · Split

libavcodec/vble.c+0−1
@@ -197,7 +197,6 @@ static av_cold int vble_decode_init(AVCodecContext *avctx) · 196 unmodified lines
197 197
198 if (!ctx->val) {198 if (!ctx->val) {
199 av_log(avctx, AV_LOG_ERROR, "Could not allocate values buffer.\n");199 av_log(avctx, AV_LOG_ERROR, "Could not allocate values buffer.\n");
200 vble_decode_close(avctx);
201 return AVERROR(ENOMEM);200 return AVERROR(ENOMEM);
202 }201 }
203 202

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