This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Upgrade to libnet 1.0704.
[perl5.git] / t / io / read.t
1 #!./perl
2
3 # $RCSfile$
4
5 print "1..1\n";
6
7 open(A,"+>a");
8 print A "_";
9 seek(A,0,0);
10
11 $b = "abcd"; 
12 $b = "";
13
14 read(A,$b,1,4);
15
16 close(A);
17
18 unlink("a");
19
20 if ($b eq "\000\000\000\000_") {
21         print "ok 1\n";
22 } else { # Probably "\000bcd_"
23         print "not ok 1\n";
24 }
25
26 unlink 'a';