GNOME Bugzilla – Bug 768761
wayland: Error check before using cached wl_display
Last modified: 2016-10-31 14:27:53 UTC
Created attachment 331387 [details] [review] wayland: Error check before using cached wl_display Hello, I'm a newbie at this place. I'm currently working for IVI system with Intel chipset. Recently I dealt with an issue which 'sometimes' failed to create a planar buffer, then wayland was disconnected. I put an error detection code then it works well.
Review of attachment 331387 [details] [review]: Overall it looks good, just a couple comments about code-style. ::: gst-libs/gst/vaapi/gstvaapidisplay_wayland.c @@ +216,3 @@ priv->display_name, g_display_types); if (info) { + wl_display_roundtrip(info->native_display); GStreamer code-style keeps a space before parentheses: wl_display_roundtrip (info->native_display); @@ +217,3 @@ if (info) { + wl_display_roundtrip(info->native_display); + if (dsp_error = wl_display_get_error(info->native_display)) ditto. @@ +218,3 @@ + wl_display_roundtrip(info->native_display); + if (dsp_error = wl_display_get_error(info->native_display)) + GST_ERROR("wayland display error detected: %d\n", dsp_error); There is no need of \n in log messages such as GST_ERROR
thanks for the patch! :D
Ah, another comment: I'd be great if you add in the commit description, what you said in the bug description, explaining why this patch is needed.
Created attachment 331452 [details] [review] wayland: Error check before using cached wl_display Thanks for the review, Victor. Please take a look.
Review of attachment 331452 [details] [review]: it looks good to me
Pushed slightly modified to avoid compiler's complain. Attachment 331452 [details] pushed as 0d1d097 - wayland: Error check before using cached wl_display