From mboxrd@z Thu Jan 1 00:00:00 1970 From: Luca Ferrari Subject: Re: cdrom and multisession Date: Tue, 24 Aug 2004 18:29:44 +0200 Sender: linux-admin-owner@vger.kernel.org Message-ID: <200408241829.44692.fluca1978@infinito.it> References: <200408231515.20852.fluca1978@infinito.it> <200408241744.27807.fluca1978@infinito.it> <2899.192.168.99.70.1093363900.squirrel@192.168.99.70> Reply-To: fluca1978@infinito.it Mime-Version: 1.0 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: In-Reply-To: <2899.192.168.99.70.1093363900.squirrel@192.168.99.70> Content-Disposition: inline List-Id: Content-Type: text/plain; charset="iso-8859-1" To: linux-admin@vger.kernel.org On Tuesday 24 August 2004 18:11 Scott Taylor's cat walking on the keybo= ard =20 wrote: Hi Scott, I'm not asking you to do my homework, just a suggestion. > > Use a rewritable aproach? > I believe this will imply to dump the original content, add the new and= =20 rewrite it all. If so, I don't like it, otherwise please explain what y= ou're=20 thinking about. > > Otherwise, how can I iterate automatically on all the session of a = cd to > > search for a specific file? > > How can you write a program if you don't know how to use a loop to it= erate > through a set or increment an integer to a maximum value? > Who said that? Do you think I'm not able to iterate other a set of valu= es? Did=20 you understand that from my e-mail address?=20 > First you'll need to know the number of sessions on your CD, or make = your > program guess with an 'or die' (or equiv) if mounting fails. > That's what I was thinking. Imagine I've got a cd in the driver, and I = don't=20 know how many sessions are there in the cd, but I know that the cd cont= ains,=20 in one of the session, a file I want to read. What I was asking here is= if=20 there is a way to know how many session are present, thus to easily ite= rate=20 without making my program to try mounting the cd and stopping at the fi= rst=20 fail, to reach the file I'm looking for. I'd like to do this in bash. >Not really quite sure what you are trying to ask us here. =A0 If you don't know the answer, please don't post. Luca --=20 Luca Ferrari, fluca1978@infinito.it - To unsubscribe from this list: send the line "unsubscribe linux-admin" = in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html