sys/: Move some cleanup stuff from the state change handler into a _reset() function...
authorJan Schmidt <thaytan@mad.scientist.com>
Thu, 8 Mar 2007 15:22:53 +0000 (15:22 +0000)
committerJan Schmidt <thaytan@mad.scientist.com>
Thu, 8 Mar 2007 15:22:53 +0000 (15:22 +0000)
commitea0d6ebf368cd7529f1315c03847c7339f77d004
treefe129d26062d83304434cab47f398c1b599badac
parent46a7bd8dfd675a747d4a750a5c8e38d6c44b351b
sys/: Move some cleanup stuff from the state change handler into a _reset() function that can be called from _finaliz...

Original commit message from CVS:
* sys/ximage/ximagesink.c: (gst_ximagesink_xcontext_clear),
(gst_ximagesink_change_state), (gst_ximagesink_reset),
(gst_ximagesink_finalize):
* sys/xvimage/xvimagesink.c: (gst_xvimagesink_change_state),
(gst_xvimagesink_reset), (gst_xvimagesink_finalize):
Move some cleanup stuff from the state change handler into a _reset()
function that can be called from _finalize(). This ensures that things
get freed even if (for some reason) the NULL->READY state transition
fails in the parent class.
Even if a parent state change fails, process our downward state change
logic instead of bailing out early.
Free the correct xcontext pointer in ximagesink's xcontext_clear.
ChangeLog
sys/ximage/ximagesink.c
sys/xvimage/xvimagesink.c