From 184778b5ed36d10f50c2f8b01a88f235ef892b05 Mon Sep 17 00:00:00 2001 From: Michael Roitzsch Date: Mon, 30 Dec 2002 14:26:50 +0000 Subject: close the port on dispose goom: do not register at video port, because we do not want the video out to call back into our stream (since the video frames are generated by post, there is no decoder that could answer) Daniel: no, this does not fix your problems :( CVS patchset: 3730 CVS date: 2002/12/30 14:26:50 --- src/post/goom/xine_goom.c | 27 +++++++++++++++------------ src/post/planar/invert.c | 8 +++++++- 2 files changed, 22 insertions(+), 13 deletions(-) diff --git a/src/post/goom/xine_goom.c b/src/post/goom/xine_goom.c index f39a77511..aa071b127 100644 --- a/src/post/goom/xine_goom.c +++ b/src/post/goom/xine_goom.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine_goom.c,v 1.12 2002/12/29 23:58:43 f1rmb Exp $ + * $Id: xine_goom.c,v 1.13 2002/12/30 14:26:50 mroi Exp $ * * GOOM post plugin. * @@ -197,16 +197,23 @@ static void goom_class_dispose(post_class_t *class_gen) } -static void goom_dispose(post_plugin_t *this) +static void goom_dispose(post_plugin_t *this_gen) { + post_plugin_goom_t *this = (post_plugin_goom_t *)this_gen; + xine_post_out_t *output = (xine_post_out_t *)xine_list_first_content(this_gen->output); + xine_video_port_t *port = *(xine_video_port_t **)output->data; + goom_close(); - free(this->xine_post.audio_input); - free(this->xine_post.video_input); - free(xine_list_first_content(this->input)); - free(xine_list_first_content(this->output)); - xine_list_free(this->input); - xine_list_free(this->output); + if (this->stream) + port->close(port, this->stream); + + free(this->post.xine_post.audio_input); + free(this->post.xine_post.video_input); + free(xine_list_first_content(this->post.input)); + free(xine_list_first_content(this->post.output)); + xine_list_free(this->post.input); + xine_list_free(this->post.output); free(this); } @@ -271,8 +278,6 @@ static int goom_port_open(xine_audio_port_t *port_gen, xine_stream_t *stream, post_audio_port_t *port = (post_audio_port_t *)port_gen; post_plugin_goom_t *this = (post_plugin_goom_t *)port->post; - this->vo_port->open( this->vo_port, stream ); - this->bits = bits; this->mode = mode; this->channels = mode_channels(mode); @@ -288,8 +293,6 @@ static void goom_port_close(xine_audio_port_t *port_gen, xine_stream_t *stream ) post_audio_port_t *port = (post_audio_port_t *)port_gen; post_plugin_goom_t *this = (post_plugin_goom_t *)port->post; - this->vo_port->close( this->vo_port, stream ); - this->stream = NULL; port->original_port->close(port->original_port, stream ); diff --git a/src/post/planar/invert.c b/src/post/planar/invert.c index 47bb197a6..304005052 100644 --- a/src/post/planar/invert.c +++ b/src/post/planar/invert.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: invert.c,v 1.6 2002/12/29 14:04:43 mroi Exp $ + * $Id: invert.c,v 1.7 2002/12/30 14:26:51 mroi Exp $ */ /* @@ -158,6 +158,12 @@ static void invert_class_dispose(post_class_t *class_gen) static void invert_dispose(post_plugin_t *this) { + post_invert_out_t *output = (post_invert_out_t *)xine_list_first_content(this->output); + xine_video_port_t *port = *(xine_video_port_t **)output->xine_out.data; + + if (output->stream) + port->close(port, output->stream); + free(this->xine_post.audio_input); free(this->xine_post.video_input); free(xine_list_first_content(this->input)); -- cgit v1.2.3