Path: utzoo!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!uakari.primate.wisc.edu!caen!sol.ctr.columbia.edu!emory!wa4mei!holos0!lbr From: lbr@holos0.uucp (Len Reed) Newsgroups: comp.lang.perl Subject: Re: Question about Perl on DOS and EOF problem. Message-ID: <1991Mar2.163306.17399@holos0.uucp> Date: 2 Mar 91 16:33:06 GMT References: <11006@jarthur.Claremont.EDU> Organization: Holos Software, Inc., Atlanta, GA Lines: 18 In article <11006@jarthur.Claremont.EDU> kevin@jarthur.claremont.edu (Kevin Fink) writes: >I am using Perl to convert some files from one format to another. The files >contain hex 1A codes (EOF markers).... >How do I get around this? The code looks something like: > >open(IN,"DATAFILE"); At this point say binmode(IN); which will put the stream into binary mode. The default is text mode, which translates CR/LF to LF and stops at the stupid-descended-from-the- days-of-CPM-for-God's-sake end of file character. -- Len Reed Holos Software, Inc. Voice: (404) 496-1358 UUCP: ...!gatech!holos0!lbr