[Bug 729195] videotestsrc: undefined behaviour in left-shift

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Tue Apr 29 08:03:56 PDT 2014


https://bugzilla.gnome.org/show_bug.cgi?id=729195
  GStreamer | gst-plugins-base | git

Luis de Bethencourt <luis> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |FIXED

--- Comment #2 from Luis de Bethencourt <luis at debethencourt.com> 2014-04-29 15:03:51 UTC ---
The two options were changing the type to guint32 in vts_color_struct or
casting to guint32 when necessary. This struct has more uses and could
potentially be hundreds of instances. So type casting is less intrusive.

The problem, as slomo reminded me, is that a guint8 gets promoted to an int
(gint32). Which means there could be sign bit flipping happening without the
type casting.

Pushed the patch:
954db90918db5532463612a0ec6a891e463a57b7

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list