From cee06643c91eb698d2ea619ee4cf2c63b3fc841c Mon Sep 17 00:00:00 2001 From: Darren Salt Date: Mon, 26 Feb 2007 19:15:15 +0000 Subject: Fix a possible crash in the eq2 plugin. The wrong width value was used for the U and V parts of the image. CVS patchset: 8631 CVS date: 2007/02/26 19:15:15 --- ChangeLog | 1 + src/post/planar/eq2.c | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 9d26fcacc..76c9d8c00 100644 --- a/ChangeLog +++ b/ChangeLog @@ -6,6 +6,7 @@ xine-lib (1.1.5) The plugins are contributed by Christoph Pfister with the help of Vincent Torri, Jamey Sharp and Christophe Thommeret. * Fix race condition in alsa audio out driver. + * Fixed a crash in the eq2 plugin. [Bug 1644312] xine-lib (1.1.4) * Mark string-type configuration items according to whether they're plain diff --git a/src/post/planar/eq2.c b/src/post/planar/eq2.c index 806a4ea6c..489733c9b 100644 --- a/src/post/planar/eq2.c +++ b/src/post/planar/eq2.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: eq2.c,v 1.16 2006/03/26 14:45:41 valtri Exp $ + * $Id: eq2.c,v 1.17 2007/02/26 19:15:15 dsalt Exp $ * * mplayer's eq2 (soft video equalizer) * Software equalizer (brightness, contrast, gamma, saturation) @@ -599,12 +599,12 @@ static int eq2_draw(vo_frame_t *frame, xine_stream_t *stream) pthread_mutex_lock (&this->lock); for (i = 0; i < 3; i++) { - int height; + int height, width; height = (i==0) ? frame->height : frame->height/2; - + width = (i==0) ? frame->width : frame->width/2; if (eq2->param[i].adjust != NULL) { eq2->param[i].adjust (&eq2->param[i], out_frame->base[i], yv12_frame->base[i], - frame->width, height, out_frame->pitches[i], yv12_frame->pitches[i]); + width, height, out_frame->pitches[i], yv12_frame->pitches[i]); } else { xine_fast_memcpy(out_frame->base[i],yv12_frame->base[i], -- cgit v1.2.3