From 074580619aa266cb4a0c047842f48caec07a9b37 Mon Sep 17 00:00:00 2001 From: van Date: Tue, 19 Aug 2008 06:23:09 +0000 Subject: fix subtitle indepth scan abort & hang. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1645 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- libhb/reader.c | 3 ++- libhb/sync.c | 9 ++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) (limited to 'libhb') diff --git a/libhb/reader.c b/libhb/reader.c index b06816d3d..0516932fb 100644 --- a/libhb/reader.c +++ b/libhb/reader.c @@ -334,7 +334,8 @@ static void ReaderFunc( void * _r ) ( audio = hb_list_item( r->job->title->list_audio, n ) ) != NULL; ++n ) { - push_buf( r, audio->priv.fifo_in, hb_buffer_init(0) ); + if ( audio->priv.fifo_in ) + push_buf( r, audio->priv.fifo_in, hb_buffer_init(0) ); } hb_list_empty( &list ); diff --git a/libhb/sync.c b/libhb/sync.c index 09ef0d9a2..524ca4d1b 100644 --- a/libhb/sync.c +++ b/libhb/sync.c @@ -111,10 +111,13 @@ int syncInit( hb_work_object_t * w, hb_job_t * job ) pv->busy |= 1; /* Initialize libsamplerate for every audio track we have */ - for( i = 0; i < hb_list_count( title->list_audio ); i++ ) + if ( ! job->indepth_scan ) { - pv->busy |= ( 1 << (i + 1) ); - InitAudio( w, i ); + for( i = 0; i < hb_list_count( title->list_audio ); i++ ) + { + pv->busy |= ( 1 << (i + 1) ); + InitAudio( w, i ); + } } /* Get subtitle info, if any */ -- cgit v1.2.3