From ee1f83092e4d6f1a7dad176595500b1d946b7a9b Mon Sep 17 00:00:00 2001 From: Jan Schmidt Date: Mon, 22 Aug 2005 19:22:34 +0000 Subject: [PATCH] gst/base/gstbasesrc.c: (gst_base_src_event_handler) Original commit message from CVS: * gst/base/gstbasesrc.c: (gst_base_src_event_handler) Don't pretend to handle seek events if the source is not seekable --- ChangeLog | 5 +++++ gst/base/gstbasesrc.c | 4 ++++ libs/gst/base/gstbasesrc.c | 4 ++++ 3 files changed, 13 insertions(+) diff --git a/ChangeLog b/ChangeLog index cdb6c40527..211187d9e8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2005-08-22 Jan Schmidt + + * gst/base/gstbasesrc.c: (gst_base_src_event_handler) + Don't pretend to handle seek events if the source is not seekable + 2005-08-22 Jan Schmidt * gst/base/gstbasesink.c: (gst_base_sink_handle_object): diff --git a/gst/base/gstbasesrc.c b/gst/base/gstbasesrc.c index 37b97d4842..637c704702 100644 --- a/gst/base/gstbasesrc.c +++ b/gst/base/gstbasesrc.c @@ -509,6 +509,10 @@ gst_base_src_event_handler (GstPad * pad, GstEvent * event) switch (GST_EVENT_TYPE (event)) { case GST_EVENT_SEEK: + if (!src->seekable) { + gst_event_unref (event); + return FALSE; + } return gst_base_src_do_seek (src, event); case GST_EVENT_FLUSH_START: /* cancel any blocking getrange */ diff --git a/libs/gst/base/gstbasesrc.c b/libs/gst/base/gstbasesrc.c index 37b97d4842..637c704702 100644 --- a/libs/gst/base/gstbasesrc.c +++ b/libs/gst/base/gstbasesrc.c @@ -509,6 +509,10 @@ gst_base_src_event_handler (GstPad * pad, GstEvent * event) switch (GST_EVENT_TYPE (event)) { case GST_EVENT_SEEK: + if (!src->seekable) { + gst_event_unref (event); + return FALSE; + } return gst_base_src_do_seek (src, event); case GST_EVENT_FLUSH_START: /* cancel any blocking getrange */