summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorphintuka <phintuka>2010-01-04 07:58:40 +0000
committerphintuka <phintuka>2010-01-04 07:58:40 +0000
commit0b45f5177924990bd574a82d33294a6a100e2eaf (patch)
tree1d30ede66927a009aabb08406397da87fe3d2d5e
parenta57ad0f84fcde6f051db2d383f4d950869b094dd (diff)
downloadxineliboutput-0b45f5177924990bd574a82d33294a6a100e2eaf.tar.gz
xineliboutput-0b45f5177924990bd574a82d33294a6a100e2eaf.tar.bz2
fe_xine_init(): Use proper cleanup functions.
fe_post_unwire(): Added check for this->stream. Fail if stream is not initialized.
-rw-r--r--xine_frontend.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/xine_frontend.c b/xine_frontend.c
index c35ade21..eaa88d3a 100644
--- a/xine_frontend.c
+++ b/xine_frontend.c
@@ -4,7 +4,7 @@
* See the main source file 'xineliboutput.c' for copyright information and
* how to reach the author.
*
- * $Id: xine_frontend.c,v 1.108 2010-01-03 21:56:10 phintuka Exp $
+ * $Id: xine_frontend.c,v 1.109 2010-01-04 07:58:40 phintuka Exp $
*
*/
@@ -652,7 +652,7 @@ static int fe_xine_init(frontend_t *this_gen, const char *audio_driver,
if(!this->video_port) {
LOGMSG("fe_xine_init: xine_open_video_driver(\"%s\") failed",
video_driver?video_driver:"(NULL)");
- xine_exit(this->xine);
+ this->fe.xine_exit(this_gen);
return 0;
}
@@ -695,7 +695,7 @@ static int fe_xine_init(frontend_t *this_gen, const char *audio_driver,
if(!this->stream) {
LOGMSG("fe_xine_init: xine_stream_new failed");
- xine_exit(this->xine);
+ this->fe.xine_exit(this_gen);
return 0;
}
@@ -857,6 +857,9 @@ static void init_dummy_ports(fe_t *this, int on)
static void fe_post_unwire(fe_t *this)
{
+ if (!this || !this->stream)
+ return;
+
xine_post_out_t *vo_source = xine_get_video_source(this->stream);
xine_post_out_t *ao_source = xine_get_audio_source(this->stream);