in reply to Re^2: $twig->flush causing output to stdout?
in thread $twig->flush causing output to stdout?
Then this s dependant on how you called the subroutine, especially in which way you specified the new filename. You should show us that code as well.