From: Jarkko Hietaniemi Date: Wed, 2 Apr 2003 04:42:40 +0000 (+0000) Subject: Cannot portably compare files if one of them is still open X-Git-Tag: accepted/trunk/20130322.191538~24494 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=65571878b040d78e1f4e2b0ef9bb7a844bdc5297;p=platform%2Fupstream%2Fperl.git Cannot portably compare files if one of them is still open (from Craig Berry). p4raw-id: //depot/perl@19130 --- diff --git a/ext/Encode/t/enc_module.t b/ext/Encode/t/enc_module.t index ac9bf3c..0910029 100644 --- a/ext/Encode/t/enc_module.t +++ b/ext/Encode/t/enc_module.t @@ -38,6 +38,7 @@ open STDOUT, ">", $file1 or die "$file1:$!"; print $obj->str, "\n"; $obj->set("¥Æ¥¹¥Èʸ»úÎó"); print $obj->str, "\n"; +close STDOUT; my $cmp = compare_text($file0, $file1); is($cmp, 0, "encoding vs. STDOUT"); @@ -51,7 +52,6 @@ while(){ is ($cmp[$i++], $_, "encoding vs. STDIN - $i"); } -close STDOUT; unlink $file1 unless $cmp; __END__