From ecd1f1805869b42a090d87f3e7dc51dea011176a Mon Sep 17 00:00:00 2001 From: Sebastian Dröge Date: Thu, 27 Sep 2012 12:33:17 +0200 Subject: insanitygstpipelinetest: Fix printing of datetime tags --- lib/insanity-gst/insanitygstpipelinetest.c | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) diff --git a/lib/insanity-gst/insanitygstpipelinetest.c b/lib/insanity-gst/insanitygstpipelinetest.c index ff3083e..791fbd6 100644 --- a/lib/insanity-gst/insanitygstpipelinetest.c +++ b/lib/insanity-gst/insanitygstpipelinetest.c @@ -244,26 +244,7 @@ send_tag (const GstTagList * list, const gchar * tag, gpointer data) GstDateTime *dt = NULL; gst_tag_list_get_date_time_index (list, tag, i, &dt); - if (gst_date_time_get_hour (dt) < 0) { - str = g_strdup_printf ("%02u-%02u-%04u", gst_date_time_get_day (dt), - gst_date_time_get_month (dt), gst_date_time_get_year (dt)); - } else { - gdouble tz_offset = gst_date_time_get_time_zone_offset (dt); - gchar tz_str[32]; - - if (tz_offset != 0.0) { - g_snprintf (tz_str, sizeof (tz_str), "(UTC %s%gh)", - (tz_offset > 0.0) ? "+" : "", tz_offset); - } else { - g_snprintf (tz_str, sizeof (tz_str), "(UTC)"); - } - - str = g_strdup_printf ("%04u-%02u-%02u %02u:%02u:%02u %s", - gst_date_time_get_year (dt), gst_date_time_get_month (dt), - gst_date_time_get_day (dt), gst_date_time_get_hour (dt), - gst_date_time_get_minute (dt), gst_date_time_get_second (dt), - tz_str); - } + str = gst_date_time_to_iso8601_string (dt); gst_date_time_unref (dt); } else { str = -- cgit v1.2.3