decoder: fix crash on invalid pointer for GST_DEBUG().
authorWind Yuan <feng.yuan@intel.com>
Fri, 17 Jan 2014 08:56:53 +0000 (16:56 +0800)
committerGwenole Beauchesne <gwenole.beauchesne@intel.com>
Wed, 22 Jan 2014 17:30:26 +0000 (18:30 +0100)
commit0e8afe1c22d6fe942c3ed452761bae445af3da9c
tree0461fc8c2538ad9be1aa800c2c70386c6eee4259
parentdeff9c775c477ff80112ae11d080dea9a7f43c9d
decoder: fix crash on invalid pointer for GST_DEBUG().

When decoding failed, or that the frame was dropped, the associated
surface proxy is not guaranteed to be present. Thus, the GST_DEBUG()
message needs to check whether the proxy is actually present or not.

https://bugzilla.gnome.org/show_bug.cgi?id=722403

[fixed gst_vaapi_surface_proxy_get_surface_id() to return VA_INVALID_ID]
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
gst-libs/gst/vaapi/gstvaapidecoder.c
gst-libs/gst/vaapi/gstvaapisurfaceproxy.c