in reply to Re: not waiting for external command to complete before getting the output
in thread not waiting for external command to complete before getting the output

cdrecord seems to be buffering output
Thanks guys. Been away making supper. Now, Seems like this silly cdrecord thing is buffering the output. I tried what was suggested and noting was output until the enture cd had completed the record (which of course by that stage is way too late). So, now the question is: how do I get hold of this output without hacking cdrecord?
perl -e 'open (FD1, "/usr/bin/cdrecord -vs -dummy -eject /mnt/test/Deb +ian/2disc.iso |"); while (<FD1>) { $_ =~ s/^M//g; print $_ if /^Track/; }; close (FD1)
My output looks like:
Track 01: 0 of 47 MB written.Track 01: 1 of 47 MB written (fifo 96%).....etc.

Thanks for the help so far.
Cheers
H
  • Comment on Re: Re: not waiting for external command to complete before getting the output
  • Download Code

Replies are listed 'Best First'.
Re: Re: Re: not waiting for external command to complete before getting the output
by Joost (Canon) on Apr 26, 2004 at 19:03 UTC