[gstreamer-bugs] [Bug 515689] New: Core is dumped in a race condition with gnonlin
GStreamer (bugzilla.gnome.org)
bugzilla-daemon at bugzilla.gnome.org
Sun Feb 10 21:50:55 PST 2008
If you have any questions why you received this email, please see the text at
the end of this email. Replies to this email are NOT read, please see the text
at the end of this email. You can add comments to this bug at:
http://bugzilla.gnome.org/show_bug.cgi?id=515689
GStreamer | gstreamer (core) | Ver: 0.10.0
Summary: Core is dumped in a race condition with gnonlin
Product: GStreamer
Version: 0.10.0
Platform: Other
OS/Version: Linux
Status: UNCONFIRMED
Severity: normal
Priority: Normal
Component: gstreamer (core)
AssignedTo: gstreamer-bugs at lists.sourceforge.net
ReportedBy: dskippy at ccs.neu.edu
QAContact: gstreamer-bugs at lists.sourceforge.net
GNOME version: Unspecified
GNOME milestone: Unspecified
# This program segfaults a dumps core. This is a reduction from my program
# there is some short of race condtion. If there's a sleep between
# the first and second gnlcomposition1.add() it fails.
import gobject
gobject.threads_init()
import pygst
pygst.require("0.10")
import gst
import time
main_loop = gobject.MainLoop()
pipeline = gst.Pipeline()
adder = gst.element_factory_make("adder")
lame = gst.element_factory_make("lame")
fakesink = gst.element_factory_make("fakesink")
pipeline.add(adder, lame,fakesink)
# taking lame out of the pipeline stops the coredump
gst.element_link_many(adder, lame, fakesink)
# Add one compostion
gnlcomposition1 = gst.element_factory_make("gnlcomposition")
audioconvert1 = gst.element_factory_make("audioconvert")
pipeline.add(gnlcomposition1, audioconvert1)
def OnPad (comp, pad):
convpad = audioconvert1.get_compatible_pad(pad, pad.get_caps())
pad.link(convpad)
gnlcomposition1.connect("pad-added", OnPad)
srcpad = audioconvert1.get_pad('src')
addersinkpad = adder.get_request_pad('sink%d')
srcpad.link(addersinkpad)
# Add second compostion
gnlcomposition2 = gst.element_factory_make("gnlcomposition")
audioconvert2 = gst.element_factory_make("audioconvert")
pipeline.add(gnlcomposition2, audioconvert2)
def OnPad (comp, pad):
convpad = audioconvert2.get_compatible_pad(pad, pad.get_caps())
pad.link(convpad)
gnlcomposition2.connect("pad-added", OnPad)
srcpad = audioconvert2.get_pad('src')
addersinkpad = adder.get_request_pad('sink%d')
srcpad.link(addersinkpad)
def add():
print "Going..."
filesrc = gst.element_factory_make("gnlfilesource")
filesrc.set_property("location", "/home/dskippy/17years.mp3")
#not givin the filesrc a duration stops the coredump
filesrc.set_property("duration", 1 * gst.SECOND)
gnlcomposition1.add(filesrc)
#taking this sleep out changes the race condition
#and stops the coredump
time.sleep(1)
dead_air = gst.element_factory_make("gnlsource")
gnlcomposition1.add(dead_air)
pipeline.set_state(gst.STATE_PLAYING)
gobject.idle_add(add)
main_loop.run()
--
See http://bugzilla.gnome.org/page.cgi?id=email.html for more info about why you received
this email, why you can't respond via email, how to stop receiving
emails (or reduce the number you receive), and how to contact someone
if you are having problems with the system.
You can add comments to this bug at http://bugzilla.gnome.org/show_bug.cgi?id=515689.
More information about the Gstreamer-bugs
mailing list