From ff8d49a4c8bf9040b941818ec7dcfb2b0e375c16 Mon Sep 17 00:00:00 2001 From: Scott D Phillips Date: Fri, 11 Nov 2016 10:38:58 -0800 Subject: [PATCH] Use intermediate guint when handling GstVideoMultiviewFlags The underlying integer type of the enum GstVideoMultiviewFlags is implementation defined and may not have the same size as guint. https://bugzilla.gnome.org/show_bug.cgi?id=774293 --- gst-libs/gst/video/video-info.c | 6 ++++-- gst/playback/gstplaybin2.c | 2 +- gst/playback/gstplaybin3.c | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/gst-libs/gst/video/video-info.c b/gst-libs/gst/video/video-info.c index 0c4edab0b3..bfbba9f477 100644 --- a/gst-libs/gst/video/video-info.c +++ b/gst-libs/gst/video/video-info.c @@ -340,6 +340,7 @@ gst_video_info_from_caps (GstVideoInfo * info, const GstCaps * caps) gint width = 0, height = 0; gint fps_n, fps_d; gint par_n, par_d; + guint multiview_flags; g_return_val_if_fail (info != NULL, FALSE); g_return_val_if_fail (caps != NULL, FALSE); @@ -421,8 +422,9 @@ gst_video_info_from_caps (GstVideoInfo * info, const GstCaps * caps) else GST_VIDEO_INFO_MULTIVIEW_MODE (info) = GST_VIDEO_MULTIVIEW_MODE_NONE; - gst_structure_get_flagset (structure, "multiview-flags", - &GST_VIDEO_INFO_MULTIVIEW_FLAGS (info), NULL); + gst_structure_get_flagset (structure, "multiview-flags", &multiview_flags, + NULL); + GST_VIDEO_INFO_MULTIVIEW_FLAGS (info) = multiview_flags; if (!gst_structure_get_int (structure, "views", &info->views)) info->views = 1; diff --git a/gst/playback/gstplaybin2.c b/gst/playback/gstplaybin2.c index 15fea65e42..fbbb590181 100644 --- a/gst/playback/gstplaybin2.c +++ b/gst/playback/gstplaybin2.c @@ -3129,7 +3129,7 @@ update_video_multiview_caps (GstPlayBin * playbin, GstCaps * caps) { GstVideoMultiviewMode mv_mode; GstVideoMultiviewMode cur_mv_mode; - GstVideoMultiviewFlags mv_flags, cur_mv_flags; + guint mv_flags, cur_mv_flags; GstStructure *s; const gchar *mview_mode_str; GstCaps *out_caps; diff --git a/gst/playback/gstplaybin3.c b/gst/playback/gstplaybin3.c index faa895b8ae..fdf0c823bb 100644 --- a/gst/playback/gstplaybin3.c +++ b/gst/playback/gstplaybin3.c @@ -2713,7 +2713,7 @@ update_video_multiview_caps (GstPlayBin3 * playbin, GstCaps * caps) { GstVideoMultiviewMode mv_mode; GstVideoMultiviewMode cur_mv_mode; - GstVideoMultiviewFlags mv_flags, cur_mv_flags; + guint mv_flags, cur_mv_flags; GstStructure *s; const gchar *mview_mode_str; GstCaps *out_caps;