summaryrefslogtreecommitdiffstats
path: root/gst-libs/gst/media-info/media-info-test.c
diff options
context:
space:
mode:
authorThomas Vander Stichele <thomas@apestaart.org>2004-03-07 20:51:10 +0000
committerThomas Vander Stichele <thomas@apestaart.org>2004-03-07 20:51:10 +0000
commit1b3ef33748906854d79dd2d430b89932db884672 (patch)
tree0ea241fa8fb6ab396f518fa50dcd4a7c799025c5 /gst-libs/gst/media-info/media-info-test.c
parent5aa8875165a582f5aa48c2137744609794040980 (diff)
downloadgst-plugins-bad-1b3ef33748906854d79dd2d430b89932db884672.tar.gz
gst-plugins-bad-1b3ef33748906854d79dd2d430b89932db884672.tar.bz2
gst-plugins-bad-1b3ef33748906854d79dd2d430b89932db884672.zip
this should more or less work correctly.
Original commit message from CVS: this should more or less work correctly.
Diffstat (limited to 'gst-libs/gst/media-info/media-info-test.c')
-rw-r--r--gst-libs/gst/media-info/media-info-test.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/gst-libs/gst/media-info/media-info-test.c b/gst-libs/gst/media-info/media-info-test.c
index 9a692144..496267d9 100644
--- a/gst-libs/gst/media-info/media-info-test.c
+++ b/gst-libs/gst/media-info/media-info-test.c
@@ -88,9 +88,11 @@ main (int argc, char *argv[])
}
g_assert (G_IS_OBJECT (info));
- if (!gst_media_info_set_source (info, "gnomevfssrc"))
+ if (!gst_media_info_set_source (info, "gnomevfssrc", &error))
{
g_print ("Could not set gnomevfssrc as a source\n");
+ g_print ("reason: %s\n", error->message);
+ g_error_free (error);
return -1;
}
@@ -101,11 +103,16 @@ main (int argc, char *argv[])
/*
stream = gst_media_info_read (info, argv[i], GST_MEDIA_INFO_ALL);
*/
- gst_media_info_read_with_idler (info, argv[i], GST_MEDIA_INFO_ALL);
- while (gst_media_info_read_idler (info, &stream) && stream == NULL)
+ gst_media_info_read_with_idler (info, argv[i], GST_MEDIA_INFO_ALL, &error);
+ while (gst_media_info_read_idler (info, &stream, &error) && stream == NULL)
/* keep idling */ g_print ("+");
g_print ("\nFILE: %s\n", argv[i]);
g_print ("stream: %p, &stream: %p\n", stream, &stream);
+ if (error)
+ {
+ g_print ("Error reading media info: %s\n", error->message);
+ g_error_free (error);
+ }
if (stream)
info_print (stream);
else