Re: pack

2002-02-21 Thread $Bill Luebkert
Sisyphus wrote: > - Original Message - > From: "Will W" <[EMAIL PROTECTED]> > >>Everyone's fascination with sysread() got me to poking around in the >>camel and cookbook a bit-- and I still can't see the advantage here of >>doing a low-level system call over using read(), which is genera

Re: pack

2002-02-21 Thread Sisyphus
- Original Message - From: "Will W" <[EMAIL PROTECTED]> > > Everyone's fascination with sysread() got me to poking around in the > camel and cookbook a bit-- and I still can't see the advantage here of > doing a low-level system call over using read(), which is generally > buffered for o

Re: pack

2002-02-21 Thread Will W
IN; } This behavior is documented in Wall, et al: _Programming perl, third ed_, pg 666 (so I guess its sort of black magic). The above bit also shows that $. does work in this mode. --Will Carl Jolley wrote on Thursday, February 21, 2002 1:35 PM Subject: Re: pack > On Thu, 21 Feb 2002, W

Re: pack

2002-02-20 Thread Torsten Förtsch
On Thu, 21 Feb 2002 01:11:01 +1100 "Sisyphus" <[EMAIL PROTECTED]> wrote: > Hi, > > Ok - so I'm running the code below and it's working as I want - unless > either of the 2 values being written to the file is 10. (ie unless $num = 8 > or 10). > > If the value is 10, then I get a couple of warnin

RE: pack

2002-02-20 Thread Joe Schell
> -Original Message- > Behalf Of Morse, Richard E. > > Hah! I know what the problem is! > > ASCII character 10 happens to be either \n -- so when you print > this number to > the file, you get a newline character for one of the bytes, so your > while() loop finds three lines in the file

RE: pack

2002-02-20 Thread Morse, Richard E.
Hah! I know what the problem is! ASCII character 10 happens to be either \n -- so when you print this number to the file, you get a newline character for one of the bytes, so your while() loop finds three lines in the file instead of two. I think that in order to read this number back out of th