From b1ca127fe13f65dea1eb64b20925336c0b7b8bf7 Mon Sep 17 00:00:00 2001 From: Heiko Schaefer Date: Mon, 11 Jun 2001 03:14:29 +0000 Subject: bugfixes for playing without sound-driver CVS patchset: 163 CVS date: 2001/06/11 03:14:29 --- src/demuxers/demux_mpeg.c | 8 ++++++-- src/xine-engine/audio_decoder.c | 4 +++- 2 files changed, 9 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/demuxers/demux_mpeg.c b/src/demuxers/demux_mpeg.c index a933fd2c4..d6bafa761 100644 --- a/src/demuxers/demux_mpeg.c +++ b/src/demuxers/demux_mpeg.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: demux_mpeg.c,v 1.15 2001/06/09 22:05:30 guenter Exp $ + * $Id: demux_mpeg.c,v 1.16 2001/06/11 03:14:29 heikos Exp $ * * demultiplexer for mpeg 1/2 program streams * reads streams of variable blocksizes @@ -368,8 +368,12 @@ static void parse_mpeg1_packet (demux_mpeg_t *this, int nID) xprintf (VERBOSE|DEMUX|AUDIO, ", audio #%d", track); - if(this->audio_fifo) + if(this->audio_fifo) { buf = this->input->read_block (this->input, this->audio_fifo, nLen); + } else { + buf = this->input->read (this->input, this->dummy_space, nLen); + return; + } if (buf == NULL) { this->status = DEMUX_FINISHED; diff --git a/src/xine-engine/audio_decoder.c b/src/xine-engine/audio_decoder.c index b4b4fdae2..0d7af2614 100644 --- a/src/xine-engine/audio_decoder.c +++ b/src/xine-engine/audio_decoder.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: audio_decoder.c,v 1.15 2001/06/09 17:07:22 guenter Exp $ + * $Id: audio_decoder.c,v 1.16 2001/06/11 03:14:29 heikos Exp $ * * * functions that implement audio decoding @@ -184,6 +184,8 @@ void *audio_decoder_loop (void *this_gen) { } void audio_decoder_init (xine_t *this) { + if (this->audio_out == NULL) + return; this->audio_fifo = fifo_buffer_new (1500, 4096); -- cgit v1.2.3