Help for this page

Select Code to Download


  1. or download this
    use strict;
    use warnings;
    ...
      die "Failed to tee to aliased STDERR and '$logfile': $!";
    
    print(STDERR "This is a test\n");
    
  2. or download this
    *STDERR = IO::Tee->new(\*STDERR2, $logfile)