So, what I think is happening is that Perl has the file open, then you use system calls to write to it. Then you do the second Perl open, which causes perl to flush out what it thinks should be in the file (which is nothing) and so you land up with an empty file.
check out Net::Ping for an easier way to do the pinging
In reply to Re: system( ), printing output & matching
by ozone
in thread system( ), printing output & matching
by zuinc
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |