summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEdward Hervey <edward@centricular.com>2017-11-04 12:19:46 +0100
committerEdward Hervey <bilboed@bilboed.com>2017-12-01 10:02:03 +0100
commit5c102dcb0956627bde2d05723cb105fdcc601d23 (patch)
treefedd5719c45e3b98f266cece2db38077277c3524
parent20cfcafa68e3596cbe1b86aa63dad6d9eb41defa (diff)
downloadgstreamer-plugins-base-5c102dcb0956627bde2d05723cb105fdcc601d23.tar.gz
videotestsrc: Fix undefined left shift
Cast value to target type
-rw-r--r--gst/videotestsrc/videotestsrc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gst/videotestsrc/videotestsrc.c b/gst/videotestsrc/videotestsrc.c
index 5e841782d..e4136a02b 100644
--- a/gst/videotestsrc/videotestsrc.c
+++ b/gst/videotestsrc/videotestsrc.c
@@ -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