waylandsink: Add exception code for setting wl_surface

Waylandsink needs exception code in gst_wayland_sink_set_window_handle().
After making sink->window, User can call
gst_wayland_sink_set_window_handle(). It is the user's fault, but
Waylandsink needs to handle the exception, if not then sink->window is
changed and rendering fails.

https://bugzilla.gnome.org/show_bug.cgi?id=747482
This commit is contained in:
Hyunil Park 2015-11-03 10:42:40 +00:00 committed by Luis de Bethencourt
parent d3db3df320
commit c9aaa4189b

View file

@ -727,6 +727,11 @@ gst_wayland_sink_set_window_handle (GstVideoOverlay * overlay, guintptr handle)
g_return_if_fail (sink != NULL);
if (sink->window != NULL) {
GST_WARNING_OBJECT (sink, "changing window handle is not supported");
return;
}
g_mutex_lock (&sink->render_lock);
GST_DEBUG_OBJECT (sink, "Setting window handle %" GST_PTR_FORMAT,