On Friday, May 3, 2002, at 02:13 , Paul Weissman wrote: [..] > when you read from a binary file like: > > open ( FD, $filename ); > binmode ( FD ); > read(FD, $buf, 2);
as you will notice from perldoc binmode - on most systems this really is not implemented as doing much of anything... It is required only on systems where they do not have a real notion of 'text mode' - as in dull flat ascii..... > now $buf has 2 bytes of your file. what kind of data type is this? it is what ever data type was in the file. [..] http://www.wetware.com/drieux/CS/lang/Perl/Beginners/readBufFoo.txt shows me pushing 'hex like' data the old fashion way back into a file - and then reading it out and reconstructing it.... does this help with the question about the fact that binmode() may not be quite what you want it to be - nor that the 'stuff in the file' - even if it is in 'ascii' "text" mode - may still require a bit of 'resolving' ... ciao drieux --- -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]