Commit 6a9d885a authored by Guillaume Desmottes's avatar Guillaume Desmottes

use GST_CLOCK_TIME_NONE as default start/end values

That's the proper GStreamer way to do it.
parent d24a53ab
......@@ -448,8 +448,8 @@ gst_dlna_src_init (GstDlnaSrc * dlna_src)
dlna_src->byte_total = 0;
dlna_src->time_seek_supported = FALSE;
dlna_src->npt_start_nanos = 0;
dlna_src->npt_end_nanos = 0;
dlna_src->npt_start_nanos = GST_CLOCK_TIME_NONE;
dlna_src->npt_end_nanos = GST_CLOCK_TIME_NONE;
dlna_src->npt_duration_nanos = 0;
dlna_src->npt_start_str = NULL;
dlna_src->npt_end_str = NULL;
......@@ -2202,8 +2202,8 @@ dlna_src_head_response_init_struct (GstDlnaSrc * dlna_src,
head_response->time_seek_npt_start_str = NULL;
head_response->time_seek_npt_end_str = NULL;
head_response->time_seek_npt_duration_str = NULL;
head_response->time_seek_npt_start = 0;
head_response->time_seek_npt_end = 0;
head_response->time_seek_npt_start = GST_CLOCK_TIME_NONE;
head_response->time_seek_npt_end = GST_CLOCK_TIME_NONE;
head_response->time_seek_npt_duration = 0;
/* BYTES portion of TIMESEEKRANGE.DLNA.ORG */
......@@ -2219,8 +2219,8 @@ dlna_src_head_response_init_struct (GstDlnaSrc * dlna_src,
head_response->available_range_idx = HEADER_INDEX_AVAILABLE_RANGE;
head_response->available_seek_npt_start_str = NULL;
head_response->available_seek_npt_end_str = NULL;
head_response->available_seek_npt_start = 0;
head_response->available_seek_npt_end = 0;
head_response->available_seek_npt_start = GST_CLOCK_TIME_NONE;
head_response->available_seek_npt_end = GST_CLOCK_TIME_NONE;
head_response->available_seek_start = 0;
head_response->available_seek_end = 0;
head_response->available_seek_cleartext_start = 0;
......
......@@ -122,8 +122,8 @@ dlna_src_parse_npt_range (GstDlnaSrc * dlna_src, const gchar * field_str,
*start_str = NULL;
*stop_str = NULL;
*total_str = NULL;
*start = 0;
*stop = 0;
*start = GST_CLOCK_TIME_NONE;
*stop = GST_CLOCK_TIME_NONE;
*total = 0;
/* Convert everything to upper case */
......
......@@ -37,7 +37,7 @@ test_parse_ntp_range (void)
do_test_parse_ntp_range ("availableSeekRange.dlna.org: 0 npt=0:00:00.000-0:00:48.716 bytes=0-5219255 cleartextbytes=0-5219255",
"0:00:00.000", "0:00:48.716", NULL, 0, 48716001280, 0);
do_test_parse_ntp_range ("npt=10.0-/* bytes=24409920-198755327/198755328",
"10.0", NULL, "*", 10000000000, 0, 0);
"10.0", NULL, "*", 10000000000, GST_CLOCK_TIME_NONE, 0);
}
int
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment