[BusyBox] awk bug
Sauder, Vernon
Vernon.Sauder at spirentcom.com
Tue May 11 16:32:33 UTC 2004
> From: Dmitry Zakharov [mailto:dmit at crp.bank.gov.ua]
> Sent: Tuesday, May 11, 2004 5:44 AM
>
> Hello,
>
> >>echo baudrate=9600 | awk -F= '{ print $2; }'
> >>
> >>This line should print "9600" (and does on RedHat) but on busybox
> >>(latest cvs, post pre10) it always prints "baudrate", no
> matter which
> >>token I ask it to print -- $1, $2, $3 or $4. The -F does
> not seem to
> >>play a difference. If the input is space separated, and -F is not
> >>given, the same output.
> >>
>
> I suppose it's something related to architecture, maybe the
> problem with
> int<->float conversions.
> Could you tell more about your environment?
>
It has nothing to do with numeric conversions. It is a strictly text error.
Try something like { echo "abc def" | awk '{print $2}' } -- it prints "abc".
I am running the latest busybox on a PowerPC (852T) custom board. I am using
gcc 3.3.2 and libc 2.3.2. Has anyone tried this on a different
architecture/environment? Does it work?
Vern
More information about the busybox
mailing list