Re: gstmm add element to pipeline test



On Fri, 2007-11-30 at 01:45 -0500, José Alburquerque wrote:
> 
> Glib::RefPtr<Bin> Bin::add(const Glib::RefPtr<Element>& element)
> {
>   bool result = gst_bin_add(gobj(), element->gobj());
> 
>   if(result)
>     return Glib::RefPtr<Bin>(this);
>   else
>     throw std::runtime_error("Bin '" + get_name() + "' does not want
> to 
> accept Element '" + element->get_name() + "'");
> }
> 
> I fixed the segfault error changing the "return" line to read "return 
> Glib::wrap(gobj(), true)".  Is this correct?  I'm submitting a
> patch.  
> Thanks.

Yes, that's correct.

-- 
murrayc murrayc com
www.murrayc.com
www.openismus.com



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]