vaapisink: fix gcc compiler warning

warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
This commit is contained in:
Víctor Manuel Jáquez Leal 2017-01-20 16:10:32 +01:00
parent f5360282bc
commit 42df9ba98c

View file

@ -1376,6 +1376,7 @@ gst_vaapisink_show_frame_unlocked (GstVaapiSink * sink, GstBuffer * src_buffer)
GstVaapiRectangle tmp_rect;
GstFlowReturn ret;
gint32 view_id;
GstVideoCropMeta *crop_meta;
if (!src_buffer) {
if (sink->video_buffer)
@ -1384,8 +1385,7 @@ gst_vaapisink_show_frame_unlocked (GstVaapiSink * sink, GstBuffer * src_buffer)
return GST_FLOW_OK;
}
GstVideoCropMeta *const crop_meta =
gst_buffer_get_video_crop_meta (src_buffer);
crop_meta = gst_buffer_get_video_crop_meta (src_buffer);
if (crop_meta) {
surface_rect = &tmp_rect;
surface_rect->x = crop_meta->x;