http://qs321.pair.com?node_id=66505


in reply to Re: Calling functions
in thread Calling functions

I don't know exactly what your code if doing, but is gen_stats is trying to read a file split_logfile is creating, you might be running into a buffering problem.

Try putting this line at the beginning of split_logfile:

local $| = 1;

This will turn autoflush on, which means Perl will output to a file immediately after a print, rathering than saving outputs up and doing them all at once.

Replies are listed 'Best First'.
(tye)Re2: Calling functions
by tye (Sage) on Mar 23, 2001 at 03:09 UTC

    That would only autoflush STDOUT, which probably isn't the problem in this case.

            - tye (but my friends call me "Tye")