Wc -Sx- Jones wrote:
> 
> James Edward Gray II wrote:
> >>>>     if (-s $output_file) {

Why are you attributing to James what Guruguhan wrote?

> There are other reasons to test for a file size prior to opening it :)
> 
> Why open a data file if it is zero length when you expect data?

What if "-s $output_file" returns true and then another process
truncates the file before you open it?

What if "-s $output_file" returns false and then another process adds
data to the file which you didn't open?


John
-- 
use Perl;
program
fulfillment

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to