6 Nov 2002 23:21
Patch for FixupTOC
<goodbyte <at> phreaker.net>
2002-11-06 22:21:21 GMT
2002-11-06 22:21:21 GMT
Hi I think I've found a bug (or maybe incompatibility with my cd-drive.) I tried ripping a cd of mine with a pre-track, and cdparanoia just went nuts. It seemed cdparanoia thought the last track had a negative number of sectors, which made it impossible to get anything from the cd except a part of the pre-track. I tracked down the bug to the multi-session fix in FixupTOC, and I've attach my patch. I don't say this is the Right Way to do it (haven't tested against a multi-session cd), but I don't think it will cause any incompabilities. Otherwice it's a GREAT TOOL. Thanx -- -- Erik MÃ¥nsson Zapp: Now that's a wave of destruction that's easy on the eyes.
diff -urN cdparanoia-III-alpha9.8/interface/common_interface.c cdparanoia-III-alpha9.8.new/interface/common_interface.c
--- cdparanoia-III-alpha9.8/interface/common_interface.c 2000-04-20 00:40:42.000000000 +0200
+++ cdparanoia-III-alpha9.8.new/interface/common_interface.c 2002-11-06 23:06:03.000000000 +0100
<at> <at> -223,7 +223,8 <at> <at>
/* adjust end of last audio track to be in the first session */
for (j = tracks-1; j >= 0; j--) {
if (j > 0 && !IS_AUDIO(d,j) && IS_AUDIO(d,j-1)) {
- if (d->disc_toc[j].dwStartSector > ms_str.addr.lba - 11400)
+ if ((d->disc_toc[j].dwStartSector > ms_str.addr.lba - 11400) &&
+ (ms_str.addr.lba - 11400 > d->disc_toc[j-1].dwStartSector))
d->disc_toc[j].dwStartSector = ms_str.addr.lba - 11400;
break;
(Continue reading)
RSS Feed