From 0e58d0f804ba63bce933b8856222276efee83b38 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim-Philipp=20M=C3=BCller?= Date: Thu, 11 Aug 2005 15:02:37 +0000 Subject: [PATCH] ext/jpeg/gstjpegdec.*: Fix crashes/invalid memory access for pictures that have a height that is not a multiple of 16... Original commit message from CVS: * ext/jpeg/gstjpegdec.c: (gst_jpeg_dec_init), (gst_jpeg_dec_chain), (gst_jpeg_dec_change_state): * ext/jpeg/gstjpegdec.h: Fix crashes/invalid memory access for pictures that have a height that is not a multiple of 16 (or rather: v_samp_factor * DCTSIZE). Also fix the state change function for downwards state changes (need to chain up to parent before destroying our resources, to make sure pads get deactivated and our chain function isn't running and using those very same resources in another thread). The jpeg line buffer only needs to be v_samp_factor*DCTSIZE lines per plane, not picture_height lines; allocate that on the stack. --- ChangeLog | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/ChangeLog b/ChangeLog index 89725a1..8bfe48f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,19 @@ +2005-08-11 Tim-Philipp Müller + + * ext/jpeg/gstjpegdec.c: (gst_jpeg_dec_init), (gst_jpeg_dec_chain), + (gst_jpeg_dec_change_state): + * ext/jpeg/gstjpegdec.h: + Fix crashes/invalid memory access for pictures that have a height + that is not a multiple of 16 (or rather: v_samp_factor * DCTSIZE). + + Also fix the state change function for downwards state changes + (need to chain up to parent before destroying our resources, to + make sure pads get deactivated and our chain function isn't + running and using those very same resources in another thread). + + The jpeg line buffer only needs to be v_samp_factor*DCTSIZE lines + per plane, not picture_height lines; allocate that on the stack. + 2005-08-10 Tim-Philipp Müller * gst/wavparse/gstwavparse.c: (gst_wavparse_stream_headers), -- 2.7.4