videotestsrc: Fix undefined left shift

Cast value to target type
This commit is contained in:
Edward Hervey 2017-11-04 12:19:46 +01:00 committed by Edward Hervey
parent 31d5ac15b2
commit c81e3e6fce

View file

@ -1206,9 +1206,9 @@ paint_tmpline_ARGB (paintinfo * p, int x, int w)
#if G_BYTE_ORDER == G_LITTLE_ENDIAN
value = (p->color->A << 0) | (p->color->R << 8) |
(p->color->G << 16) | (p->color->B << 24);
(p->color->G << 16) | ((guint32) p->color->B << 24);
#else
value = (p->color->A << 24) | (p->color->R << 16) |
value = ((guint32) p->color->A << 24) | (p->color->R << 16) |
(p->color->G << 8) | (p->color->B << 0);
#endif