Re: [linux-minidisc] scsi test tool using cdrtools/libscg


On Sat, Jun 05, 2010 at 06:18:54PM +0200, Thomas Arp wrote:
 > > bash-3.2# ./himdformat_scg 3,0,0
> > Cannot open scsi driver.
> > 
> > Hmm?! Am I missing something? I'm calling this as root so it can't be
> > a permissions thing.
> > 
> > I will continue to test anyway.
> > 
> > Adrian
> 
> Please use "strcpy(dev, argv[1]);" in line 42 of himdformat_scg.c 
> instead of "memcpy(dev, argv[1], sizeof(argv[1]));".
> Else the last char will be replaced by the terminating "\0" .
> 
> Sorry, i sent you the information before but i´ve forgotten to
> send a patch.
> You can also try himdscsitest.

Jeppers, that fixed it. Strange, I was pretty sure I already changed
it when you suggested it. Anyway, it works now:

minimac2:basictools zedv$ ./himdformat_scg 3,0,0
SCSI command sent successfully.
minimac2:basictools zedv$

We can finally start putting the pieces together and implement a
working formatting (and other useful SCSI commands) function on
QHiMDTransfer on _all_ supported platforms. Great work, guys!

I will send updated patches for cdrtools and build instructions for
MacOS X to the list soon.

Adrian