Hi Thomas,

thank you for the detailed analysis.

On Tue, 29 Mar 2016 17:58:53 +0200
"Thomas Schmitt" <[email protected]> wrote:

> i send a copy of this comment to [email protected]
> because i believe to see a bug.

I agree and I take the blame.

> -----------------------------------------------------------------
> Fix proposal:
> (Not even compiled yet. I need to break out an old cheat sheet.)
> -----------------------------------------------------------------
> 
> Increment track counter after a CD-TEXT buffer was recorded.
> This is necessary for the case that the same text pack contains a
> complete further text.
> 
> --- ./lib/driver/cdtext.c.orig  2014-09-24 22:53:52.000000000 +0200
> +++ ./lib/driver/cdtext.c       2016-03-29 17:23:40.184363311 +0200
> @@ -688,8 +688,9 @@ cdtext_data_init(cdtext_t *p_cdtext, uin
>                    cdtext_set(p_cdtext, CDTEXT_FIELD_ISRC, buffer,
> pack.i_track, "ISO-8859-1"); break;
>              }
>              i_buf = 0;
> +            pack.i_track++;
>  
>            }
>            if (pack.db_chars)
>              j+=2;

This should work and is the least intrusive fix.
For the sake of readability, I would suggest to introduce a new
variable and not alter the contents of `pack'.

To test the fix, it would be good to have the raw cdtext blob from
the disc of the bug reporter.

Regards
Leon

Reply via email to