ges-asset: Propagate errors from GInitable

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5981>
This commit is contained in:
Philippe Normand 2023-11-29 10:42:27 +00:00 committed by GStreamer Marge Bot
parent 86ab695e8d
commit a5e8dedff0

View file

@ -1308,10 +1308,8 @@ ges_asset_request (GType extractable_type, const gchar * id, GError ** error)
iface = g_type_interface_peek (klass, G_TYPE_INITABLE); iface = g_type_interface_peek (klass, G_TYPE_INITABLE);
if (iface->init) { if (iface->init) {
/* FIXME: allow the error to be set, which GInitable is designed
* for! */
asset = g_initable_new (asset_type, asset = g_initable_new (asset_type,
NULL, NULL, "id", real_id, "extractable-type", NULL, error, "id", real_id, "extractable-type",
extractable_type, NULL); extractable_type, NULL);
} else { } else {
GST_INFO ("Tried to create an Asset for type %s but no ->init method", GST_INFO ("Tried to create an Asset for type %s but no ->init method",