GNOME Bugzilla – Bug 626425
cog_virt_frame_new_convert_u8 has bogus source data
Last modified: 2010-09-06 09:52:43 UTC
cogvirtframe.c:1874 allocates temporary storage that is never filled cogvirtframe.c:1859 uses this as a source rather than 'src' set on the previous line Sorry no gstreamer patch, I have my own private libcog with this applied: --- a/cog/cogvirtframe.c +++ b/cog/cogvirtframe.c @@ -2170,7 +2170,7 @@ convert_u8_s16 (CogFrame * frame, void *_dest, int component, int i) int16_t *src; src = cog_virt_frame_get_line (frame->virt_frame1, component, i); - orc_convert_u8_s16 (dest, frame->virt_priv, + orc_convert_u8_s16 (dest, src, frame->components[component].width); } @@ -2185,7 +2185,6 @@ cog_virt_frame_new_convert_u8 (CogFrame * vf) virt_frame = cog_frame_new_virtual (vf->domain, format, vf->width, vf->height); virt_frame->virt_frame1 = vf; virt_frame->render_line = convert_u8_s16; - virt_frame->virt_priv = cog_malloc (sizeof (int16_t) * vf->width); return virt_frame; }
commit 62ae33d3d6e4cbfdaaf1a746a6626ff85bde7c99 Author: Jonathan Rosser <jonathan.rosser@rd.bbc.co.uk> Date: Sun Sep 5 15:34:13 2010 -0700 cog: Fix cog_virt_frame_new_convert_u8() Conversion was using uninitialized data instead of source frame. Fixes #626425.