[Bug 674080] New: dvbsrc internal data flow error
GStreamer (bugzilla.gnome.org)
bugzilla at gnome.org
Fri Apr 13 14:35:49 PDT 2012
https://bugzilla.gnome.org/show_bug.cgi?id=674080
GStreamer | gst-plugins-bad | 0.10.22
Summary: dvbsrc internal data flow error
Classification: Platform
Product: GStreamer
Version: 0.10.22
OS/Version: Linux
Status: UNCONFIRMED
Severity: normal
Priority: Normal
Component: gst-plugins-bad
AssignedTo: gstreamer-bugs at lists.freedesktop.org
ReportedBy: frankie.eymard at gmail.com
QAContact: gstreamer-bugs at lists.freedesktop.org
GNOME version: ---
The code has changed in 0.10.23 but the rootcause remains i.e. unlock() spec is
not fulfilled:
"Unlock any pending access to the resource. Subclasses should unblock any
blocked function ASAP. In particular, any create() function in progress should
be unblocked and should return GST_FLOW_WRONG_STATE. Any future create()
function call should also return GST_FLOW_WRONG_STATE until the unlock_stop()
function has been called."
http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/GstBaseSrc.html
gst_dvbsrc_unlock() calls gst_poll_set_flushing() with flushing set to TRUE
http://cgit.freedesktop.org/gstreamer/gst-plugins-bad/tree/sys/dvb/gstdvbsrc.c?id=RELEASE-0.10.23#n1090
gst_poll_wait() returns -1, with errno set to EBUSY
http://cgit.freedesktop.org/gstreamer/gst-plugins-bad/tree/sys/dvb/gstdvbsrc.c?id=RELEASE-0.10.23#n921
gst_dvbsrc_read_device() returns NULL
http://cgit.freedesktop.org/gstreamer/gst-plugins-bad/tree/sys/dvb/gstdvbsrc.c?id=RELEASE-0.10.23#n953
gst_dvbsrc_create() returns GST_FLOW_ERROR instead of GST_FLOW_WRONG_STATE
http://cgit.freedesktop.org/gstreamer/gst-plugins-bad/tree/sys/dvb/gstdvbsrc.c?id=RELEASE-0.10.23#n966
My patch for 0.10.22 follows.
diff -dur gst-plugins-bad-0.10.22/sys/dvb/gstdvbsrc.c
gst-plugins-bad-0.10.22-patch/sys/dvb/gstdvbsrc.c
--- gst-plugins-bad-0.10.22/sys/dvb/gstdvbsrc.c 2011-02-20
22:34:03.000000000 +0100
+++ gst-plugins-bad-0.10.22-patch/sys/dvb/gstdvbsrc.c 2011-08-11
11:54:08.959738425 +0200
@@ -974,13 +977,17 @@
object = GST_DVBSRC (element);
GST_LOG ("fd_dvr: %d", object->fd_dvr);
+ if (object->need_unlock) {
+ GST_DEBUG_OBJECT (object, "Unlock device");
+ return GST_FLOW_WRONG_STATE;
+ }
+
//g_object_get(G_OBJECT(object), "blocksize", &buffer_size, NULL);
buffer_size = DEFAULT_BUFFER_SIZE;
/* device can not be tuned during read */
g_mutex_lock (object->tune_mutex);
-
if (object->fd_dvr > -1) {
/* --- Read TS from DVR device --- */
GST_DEBUG_OBJECT (object, "Reading from DVR device");
@@ -994,6 +1001,9 @@
caps = gst_pad_get_caps (GST_BASE_SRC_PAD (object));
gst_buffer_set_caps (*buf, caps);
gst_caps_unref (caps);
+ } else if (object->need_unlock) {
+ GST_DEBUG_OBJECT (object, "Unlock device");
+ retval = GST_FLOW_WRONG_STATE;
} else {
GST_DEBUG_OBJECT (object, "Failed to read from device");
gst_element_post_message (GST_ELEMENT_CAST (object),
--
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list