You're right. A plain filehandle (as likely opened by File::Binary) is an IO::Handle object. And these don't know about the ->binmode method:
Q:\>perl -le "open my $fh, $^X or die $!; $fh->binmode"
Can't locate object method "binmode" via package "IO::Handle" at -e li
+ne 1.
So the easiest fix approach would be to use File::HandleIO::File objects instead of filenames, but I haven't looked at what API File::Binary uses. It could also make sense to patch File::Binary to use files (as the module name implies). |