<br><div><span class="gmail_quote">On 1/19/07, <b class="gmail_sendername">Edward Hervey</b> <<a href="mailto:bilboed@gmail.com">bilboed@gmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
On 1/18/07, Vinayak <<a href="mailto:vinayak.pane@gmail.com">vinayak.pane@gmail.com</a>> wrote:<br>> Hi,<br>><br>> On 1/18/07, ensonic <<a href="mailto:ensonic@hora-obscura.de">ensonic@hora-obscura.de</a>
> wrote:<br>> > hi,<br>> ><br>> > On 2:10:29 pm 18/01/2007 Vinayak <<a href="mailto:vinayak.pane@gmail.com">vinayak.pane@gmail.com</a>> wrote:<br>> > ><br>> > > Hi Everyone,<br>
> > > My gst-application gets stuck at gst_object_unref function which is<br>> > > called after the main loop is over and pipeline state is set to NULL.<br>> ><br>> > whats happening? a crash? for the refcount related thing you might wanna
<br>> > try <a href="http://refdbg.sf.net">http://refdbg.sf.net</a> . You could also attach your source, so that we<br>> can<br>> > look at it.<br>><br>> No there is no crash. It doesn't terminate at all , I have to kill that
<br>> process.<br><br> hmm... are you shutting down your pipeline from a signal callback and<br>not from a bus message by any chance ? It sems like a deadlock because<br>you try to shut down the pipeline from a streaming thread.
</blockquote><div><br>No, In my application:-<br><br></div>{<br>. /* created elements */<br>..<br>.. <br> bus = gst_pipeline_get_bus (GST_PIPELINE (pipeline));<br> gst_bus_add_watch (bus, bus_call, loop);<br> gst_object_unref (bus);
<br><br> /* put all elements in a bin */<br> gst_bin_add_many (GST_BIN (pipeline),<br> source, encoder, sink, NULL);<br><br> gst_element_link (source, encoder);<br> gst_element_link (encoder, sink);<br>
<br> /* Now set to playing and iterate. */<br> g_print ("APP: Setting to PLAYING\n");<br> gst_element_set_state (pipeline, GST_STATE_PLAYING);<br> g_print ("APP: Running\n");<br> g_main_loop_run (loop);
<br> /* clean up nicely */<br> g_print ("APP: Returned, stopping playback\n");<br> gst_element_set_state (pipeline, GST_STATE_NULL);<br> g_print ("APP: Deleting pipeline\n");<br> gst_object_unref (GST_OBJECT (pipeline));
<br><br> return 0;<br>}<br><br>Here the bus is already unref. The application hangs at last line ==> gst_object_unref(GST_OBJECT(pipeline))<br><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
As mentionned before, seeing your code would be much easier to spot the error.</blockquote><div><br>Thanks, <br>
--vinayak<br>
<br><br></div></div>