Browse Source

h264: check one context_init() allocation

Signed-off-by: Anton Khirnov <anton@khirnov.net>
tags/n2.1
Vittorio Giovara Anton Khirnov 12 years ago
parent
commit
c1076d8479
1 changed files with 5 additions and 1 deletions
  1. +5
    -1
      libavcodec/h264.c

+ 5
- 1
libavcodec/h264.c View File

@@ -1637,7 +1637,11 @@ static int decode_update_thread_context(AVCodecContext *dst,
av_log(dst, AV_LOG_ERROR, "Could not allocate memory for h264\n");
return ret;
}
context_init(h);
ret = context_init(h);
if (ret < 0) {
av_log(dst, AV_LOG_ERROR, "context_init() failed.\n");
return ret;
}

for (i = 0; i < 2; i++) {
h->rbsp_buffer[i] = NULL;


Loading…
Cancel
Save