in reply to getting rid of a warning

Are you sure you need to change the STDOUT? Any chance you actually need to change the select()ed filehandle?

open my $FH, '>', $POST_FILE or die "Can't redirect STDOUT"; my $oldFH = select($FH); ... select($oldFH);
Of course this depends on whether you need to change the STDOUT for a subprocess or want to change where print "foo\n"; goes. In the later case you'd rather use the select(). Keep in mind that the select()ed filehandle may already be changed and then your STDOUT change will not have any effect.