Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
Re: sending an email to a perl scriptby grinder (Bishop) |
on Nov 16, 2006 at 17:37 UTC ( [id://584531]=note: print w/replies, xml ) | Need Help?? |
I don't think it has anything to do with buffering. I would say that the code is failing to open the file, but it doesn't tell you why, since the code doesn't print $! in the event of an error. (I don't know if you are paraphrasing the code, and omitting the error check). Another possibility is that something in the while is calling exit, or dying. Again, without seeing the code, it's difficult to know. Can you strip the program down to a bare minimum, for instance, the while loop just counts the number of lines, and print that to the logfile. A final possibility is that you are opening the output file for create, not append. Maybe the subsequent run trashes the file each time. • another intruder with the mooring in the heart of the Perl
In Section
Seekers of Perl Wisdom
|
|