aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libavcodec/h264.c2
-rw-r--r--libavcodec/svq3.c5
2 files changed, 1 insertions, 6 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index 9198d7cb50..318c1c8355 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -979,7 +979,7 @@ int ff_h264_frame_start(H264Context *h){
/* can't be in alloc_tables because linesize isn't known there.
* FIXME: redo bipred weight to not require extra buffer? */
for(i = 0; i < s->avctx->thread_count; i++)
- if(!h->thread_context[i]->s.obmc_scratchpad)
+ if(h->thread_context[i] && !h->thread_context[i]->s.obmc_scratchpad)
h->thread_context[i]->s.obmc_scratchpad = av_malloc(16*2*s->linesize + 8*2*s->uvlinesize);
/* some macroblocks can be accessed before they're available in case of lost slices, mbaff or threading*/
diff --git a/libavcodec/svq3.c b/libavcodec/svq3.c
index df2acd8955..4a4a1c52cd 100644
--- a/libavcodec/svq3.c
+++ b/libavcodec/svq3.c
@@ -796,11 +796,6 @@ static av_cold int svq3_decode_init(AVCodecContext *avctx)
unsigned char *extradata;
unsigned int size;
- if(avctx->thread_count > 1){
- av_log(avctx, AV_LOG_ERROR, "SVQ3 does not support multithreaded decoding, patch welcome! (check latest SVN too)\n");
- return -1;
- }
-
if (ff_h264_decode_init(avctx) < 0)
return -1;