The 'play tr m:s.f ...' interface is broken, such that cdcontrol sometimes rejects a minute:second offset improperly, saying that 'Track x is not that long.' Other times, when it should reject the request (eg, 'play 12 35:0'), an Input/Output error occurs instead. Fix: The bug is in function play(), at label Play_Relative_Addresses, where the msf.(minute|second|frame) fields taken out of toc_buffer[] are treated as if they were the duration of each track, when in fact they are the cumulative *start* of each track. To convert to duration, which is needed to range check the 'play track m:s.f' command, something like happens in prtrack() needs to happen. That is, pull the msf for this and the next track, convert both to lba, subtract, and convert back to msf. This is probably an easy bug to fix, except for the 13 different invocation varieties allowed. How-To-Repeat: [Note: 5.x has a fix for a separate (track - 1) problem that is necessary to reproduce in exactly the way shown here.] cdcontrol> info Starting track = 1, ending track = 19, TOC size = 162 bytes track start duration block length type ------------------------------------------------- 1 0:02.00 3:17.18 0 14793 audio 2 3:19.18 3:54.25 14793 17575 audio 3 7:13.43 2:43.55 32368 12280 audio 4 9:57.23 3:40.45 44648 16545 audio 5 13:37.68 2:03.74 61193 9299 audio 6 15:41.67 3:06.58 70492 14008 audio 7 18:48.50 2:25.66 84500 10941 audio 8 21:14.41 3:09.23 95441 14198 audio 9 24:23.64 6:36.19 109639 29719 audio 10 31:00.08 4:56.49 139358 22249 audio 11 35:56.57 4:48.60 161607 21660 audio 12 40:45.42 2:43.60 183267 12285 audio [...] cdcontrol> play 1 0:30 Track 1 is not that long. cdcontrol> play 11 30:00 cdcontrol: Input/output error
This is a patch for fixing this problem. This patch is created for CVS Revision 1.48.8.1. But it can use to 1.53.
this issue is still present in 9.0 (r219727). i've attached the patch again, because the initial patch didn't apply cleanly, due to several changes made to cdcontrol since 2003 (year the initial patch was submitted). it would be nice somebody can take a look at this patch after all these years. cheers. alex -- a13x
For bugs matching the following criteria: Status: In Progress Changed: (is less than) 2014-06-01 Reset to default assignee and clear in-progress tags. Mail being skipped
Keyword: patch or patch-ready – in lieu of summary line prefix: [patch] * bulk change for the keyword * summary lines may be edited manually (not in bulk). Keyword descriptions and search interface: <https://bugs.freebsd.org/bugzilla/describekeywords.cgi>