diff -r 88bf59e8da5f -r bd0ad44171e7 gst-plugins-nuvdemux/nuvdemux/gstnuvdemux.c --- a/gst-plugins-nuvdemux/nuvdemux/gstnuvdemux.c Mon Apr 02 16:57:57 2007 +0100 +++ b/gst-plugins-nuvdemux/nuvdemux/gstnuvdemux.c Mon Apr 23 18:50:32 2007 +0100 @@ -229,7 +229,7 @@ nuv_frame_header fh; /* anothers info */ - gint64 header_lengh; + guint64 header_lengh; gint64 time_start; gint64 time_diff; gint64 time_qos; @@ -698,7 +698,6 @@ gst_nuv_demux_validate_header (nuv_frame_header *h) { gboolean valid = FALSE; - //g_debug ("Type %d = Compression %d", h->i_type, h->i_compression); //g_usleep (1 * G_USEC_PER_SEC ); switch (h->i_type) { /* @@ -799,7 +798,6 @@ h = nuv->priv->fh; if (h.i_type == 'R') { - nuv->priv->offset += h.i_length; goto done; } @@ -1044,7 +1042,7 @@ } GST_DEBUG_OBJECT (nuv, "CREATING INDEX: DONE : DURATION Bytes/Sec: %" G_GUINT64_FORMAT "/%" G_GUINT64_FORMAT, nuv->priv->offset, nuv->priv->duration_time); - + nuv->priv->duration_bytes = nuv->priv->offset; nuv->priv->offset = nuv->priv->header_lengh; @@ -1107,8 +1105,6 @@ if (nuv->priv->mode == NUV_PULL_MODE) { gst_nuv_demux_create_seek_index (nuv); } - nuv->priv->state = GST_NUV_DEMUX_FRAME_HEADER; - break; case GST_NUV_DEMUX_FRAME_HEADER: res = gst_nuv_demux_read_head_frame (nuv); @@ -1175,6 +1171,7 @@ return ret; } + if (nuv->priv->mode == NUV_PULL_MODE) { ret = gst_pad_pull_range (nuv->priv->sinkpad, nuv->priv->offset, size, buffer); if (ret == GST_FLOW_OK) {