diff --git a/media/libtheora/bug468275-r18219.patch b/media/libtheora/bug468275-r18219.patch new file mode 100644 index 000000000000..7b64b4195a2c --- /dev/null +++ b/media/libtheora/bug468275-r18219.patch @@ -0,0 +1,22 @@ +diff --git a/media/libtheora/lib/state.c b/media/libtheora/lib/state.c +--- a/media/libtheora/lib/state.c ++++ b/media/libtheora/lib/state.c +@@ -583,17 +583,17 @@ static int oc_state_ref_bufs_init(oc_the + ref_frame_szfrag_buf_offs= + _ogg_malloc(_state->nfrags*sizeof(*frag_buf_offs)); + if(ref_frame_data==NULL||frag_buf_offs==NULL){ + _ogg_free(frag_buf_offs); +- _ogg_free(ref_frame_data); ++ oc_aligned_free(ref_frame_data); + return TH_EFAULT; + } + /*Set up the width, height and stride for the image buffers.*/ + _state->ref_frame_bufs[0][0].width=info->frame_width; + _state->ref_frame_bufs[0][0].height=info->frame_height; + _state->ref_frame_bufs[0][0].stride=yhstride; + _state->ref_frame_bufs[0][1].width=_state->ref_frame_bufs[0][2].width= + info->frame_width>>hdec; diff --git a/media/libtheora/lib/state.c b/media/libtheora/lib/state.c index fa47913b03ed..5e7b0ae65185 100644 --- a/media/libtheora/lib/state.c +++ b/media/libtheora/lib/state.c @@ -588,7 +588,7 @@ static int oc_state_ref_bufs_init(oc_theora_state *_state,int _nrefs){ _ogg_malloc(_state->nfrags*sizeof(*frag_buf_offs)); if(ref_frame_data==NULL||frag_buf_offs==NULL){ _ogg_free(frag_buf_offs); - _ogg_free(ref_frame_data); + oc_aligned_free(ref_frame_data); return TH_EFAULT; } /*Set up the width, height and stride for the image buffers.*/ diff --git a/media/libtheora/update.sh b/media/libtheora/update.sh index 5ba4725fc7d2..17064fa513c9 100644 --- a/media/libtheora/update.sh +++ b/media/libtheora/update.sh @@ -79,3 +79,4 @@ cp $1/include/theora/theoradec.h ./include/theora/theoradec.h cp $1/include/theora/theoraenc.h ./include/theora/theoraenc.h cp $1/include/theora/codec.h ./include/theora/codec.h patch -p3 < ./bug625773-r17780.patch +patch -p3 < ./bug468275-r18219.patch