in reply to Re: How to find Unicode: 0x13 in File
in thread How to find Unicode: 0x13 in File
I may be wrong here, but if I am, I will learn something new :)
Could you not read in few MB's of the file (if it is big enough) and then unpack it and then test to see if the character matches 0x13?
Something like:open (my $fh, '<', 'file') or die "$!\n"; binmode($fh); while(read $fh, my $char, 0x01){ $buf = unpack('H*', $char); if ($buf =~ /13/){ print "found 0x13\n" } }
Im not up to par on unicode so I could be way off.Contents of 'file': '.Eg5eEfx`.' #'.' = 0x13;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: How to find Unicode: 0x13 in File
by choroba (Cardinal) on Nov 18, 2016 at 16:51 UTC | |
by james28909 (Deacon) on Nov 18, 2016 at 17:24 UTC | |
by AnomalousMonk (Archbishop) on Nov 18, 2016 at 19:57 UTC | |
by james28909 (Deacon) on Nov 19, 2016 at 15:55 UTC | |
by AnomalousMonk (Archbishop) on Nov 19, 2016 at 17:27 UTC |