If you haven't already, try setting
$| = 1;
$| is also known as $OUTPUT_AUTOFLUSH if you use English - if you set it to a true value, then bufferring is (effectively) switched off.
The Camel Book says:
$|
$OUTPUT_AUTOFLUSH
autoflush HANDLE EXPR
If set to nonzero, forces an fflush(3) after every write or print on the currently selected output channel. (This is called "command buffering". Contrary to popular belief, setting this variable does not turn off buffering.) Default is 0, which on many systems means that STDOUT will default to being line buffered if output is to the terminal, and block buffered otherwise. Setting this variable is useful primarily when you are outputting to a pipe, such as when you are running a Perl script under rsh and want to see the output as it's happening. This has no effect on input buffering. If you have a need to flush a buffer immediately after setting $|, you may simply print ""; rather than waiting for the next print to flush it. (Mnemonic: when you want your pipes to be piping hot.)
The Perl Cookbook explains this in some detail: see section 7.12 - it also gives examples. And it says 'See Also':
The $| entry in perlvar (1), and in the "Special Variables" section of Chapter 2 of Programming Perl; the documentation for the standard FileHandle and IO::Handle modules (also in Chapter 7 of Programming Perl ); the select function in perlfunc (1) and in Chapter 3 of Programming Perl
Hope this helps - andy.
In reply to buffering problem? Re: SSI and perl script problem
by andye
in thread SSI and perl script problem
by LiTinOveWeedle
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |