diff options
author | Rodeo <[email protected]> | 2011-09-09 23:32:53 +0000 |
---|---|---|
committer | Rodeo <[email protected]> | 2011-09-09 23:32:53 +0000 |
commit | 11cd3ab9c4a3f5448b6058fefcebab01b9a926dc (patch) | |
tree | bd8fd99df954d5b2cd0edcfd31254f40e3bf4d07 /libhb/work.c | |
parent | a25b6621a54eef55fffbfe9d2cfb4987327e3434 (diff) |
libhb: fix incorrect decrementing of audio->config.out.track; it starts at 1, not 0. Also, explicitly log that we are dropping the track when we find an incompatible passthru.
Fixes:
[01:26:41] Sample rate 24000 not supported (ca_haac). Using 32kHz for track 1
track 1 suddenly becomes track 0:
[01:26:41] work: sanitizing track 0 mixdown Dolby Pro Logic II to Stereo
[01:26:41] work: sanitizing track 0 audio bitrate 160 to 80
[…]
[01:26:41] * audio track 0
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4210 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/work.c')
-rw-r--r-- | libhb/work.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/libhb/work.c b/libhb/work.c index 035d9c664..86f453ef1 100644 --- a/libhb/work.c +++ b/libhb/work.c @@ -540,10 +540,9 @@ static void do_job( hb_job_t * job ) { audio = hb_list_item( title->list_audio, i ); if( ( audio->config.out.codec & HB_ACODEC_PASS_FLAG ) && - !( audio->config.in.codec & audio->config.out.codec & - HB_ACODEC_PASS_MASK ) ) + !( audio->config.in.codec & audio->config.out.codec & HB_ACODEC_PASS_MASK ) ) { - hb_log( "Passthru requested and input codec is not the same as output codec for track %d", + hb_log( "Passthru requested and input codec is not the same as output codec for track %d, dropping track", audio->config.out.track ); hb_list_rem( title->list_audio, audio ); free( audio ); @@ -582,8 +581,8 @@ static void do_job( hb_job_t * job ) } /* Adjust output track number, in case we removed one. * Output tracks sadly still need to be in sequential order. - */ - audio->config.out.track = i++; + * Note: out.track starts at 1, i starts at 0 */ + audio->config.out.track = ++i; } int requested_mixdown = 0; |