[Bug 788457] Memory leak in videowidgettest.cpp

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Thu Oct 5 09:34:34 UTC 2017


https://bugzilla.gnome.org/show_bug.cgi?id=788457

George Kiagiadakis <gkiagia at tolabaki.gr> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |gkiagia at tolabaki.gr
         Resolution|---                         |INVALID

--- Comment #1 from George Kiagiadakis <gkiagia at tolabaki.gr> ---
I disagree.

"group" in this scope is a QButtonGroup, which is a QWidget, which is a QObject
and it is constructed with "this" as a parent, therefore it "belongs" to the
QObject ancestor instance of this class.

When an exception is thrown in a constructor, the destructor of this object is
not called, but the destructors of its ancestor classes *are* called, since
they have successfully completed their execution already (in other words, the
ancestor QObject is a fully constructed instance at this point, therefore it
needs to be destructed).

Therefore, the QObject destructor of this instance *is* called after "throw",
so the QButtonGroup is automatically destroyed, together with all the other
widgets that are set up in m_ui.setupUi(this);

-- 
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