mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-12 02:54:11 +00:00
ges-launch: Add a proper error message on errors
This commit is contained in:
parent
deb88a1551
commit
ff15c17afb
1 changed files with 11 additions and 2 deletions
|
@ -326,11 +326,20 @@ static void
|
|||
bus_message_cb (GstBus * bus, GstMessage * message, GMainLoop * mainloop)
|
||||
{
|
||||
switch (GST_MESSAGE_TYPE (message)) {
|
||||
case GST_MESSAGE_ERROR:
|
||||
g_printerr ("ERROR\n");
|
||||
case GST_MESSAGE_ERROR:{
|
||||
GError *err = NULL;
|
||||
gchar *dbg_info = NULL;
|
||||
|
||||
gst_message_parse_error (message, &err, &dbg_info);
|
||||
g_printerr ("ERROR from element %s: %s\n",
|
||||
GST_OBJECT_NAME (message->src), err->message);
|
||||
g_printerr ("Debugging info: %s\n", (dbg_info) ? dbg_info : "none");
|
||||
g_error_free (err);
|
||||
g_free (dbg_info);
|
||||
seenerrors = TRUE;
|
||||
g_main_loop_quit (mainloop);
|
||||
break;
|
||||
}
|
||||
case GST_MESSAGE_EOS:
|
||||
if (repeat > 0) {
|
||||
g_printerr ("Looping again\n");
|
||||
|
|
Loading…
Reference in a new issue