summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/Encode/t/perlio.t2
1 files changed, 2 insertions, 0 deletions
diff --git a/ext/Encode/t/perlio.t b/ext/Encode/t/perlio.t
index 52a161b980..936eeb0b63 100644
--- a/ext/Encode/t/perlio.t
+++ b/ext/Encode/t/perlio.t
@@ -65,6 +65,7 @@ for my $e (qw/euc-jp shiftjis 7bit-jis iso-2022-jp iso-2022-jp-1/){
SKIP:{
skip "$e: !perlio_ok", 1 unless perlio_ok($e) or $DEBUG;
open $fh, ">:encoding($e)", $pfile or die "$sfile : $!";
+ binmode $fh;
$fh->autoflush(0);
print $fh $utext;
close $fh;
@@ -78,6 +79,7 @@ for my $e (qw/euc-jp shiftjis 7bit-jis iso-2022-jp iso-2022-jp-1/){
# this time print line by line.
# works even for ISO-2022!
open $fh, ">:encoding($e)", $pfile or die "$sfile : $!";
+ binmode $fh;
$fh->autoflush(1);
for my $l (@uline) {
print $fh $l;