Make sure VA display is valid when created with an explicit "display" name.

This commit is contained in:
gb 2010-03-23 15:34:51 +00:00
parent 3daf619006
commit 5d44dace53

View file

@ -116,8 +116,11 @@ gst_vaapisink_destroy(GstVaapiSink *sink)
static inline gboolean
gst_vaapisink_ensure_display(GstVaapiSink *sink)
{
if (!sink->display)
if (!sink->display) {
sink->display = gst_vaapi_display_x11_new(sink->display_name);
if (!sink->display || !gst_vaapi_display_get_display(sink->display))
return NULL;
}
return sink->display != NULL;
}