Thread Offene Datei unter Windows lesen
(2 answers)
Opened by bianca at 2013-10-01 22:15
nimm zum Einlesen eines Binärfiles read():
Code (perl): (dl
)
1 2 3 4 5 6 7 8 my $content = ''; my $buffer; my $len = 65536; open( my $fh, '<:raw', $file ); while ( read( $fh, $buffer, $len ) ) { $content .= $buffer; } Editiert von FIFO: typo , statt ; Last edited: 2013-10-02 23:16:42 +0200 (CEST) Everyone knows that debugging is twice as hard as writing a program in the first place. So if you're as clever as you can be when you write it, how will you ever debug it? -- Brian Kernighan: "The Elements of Programming Style"
|