[Toybox] grep -o oddity
enh
enh at google.com
Fri Feb 12 16:51:26 PST 2021
this doesn't work:
/tmp/toybox$ echo "a1234b" | grep -o [0-9]*
1234
/tmp/toybox$ echo "a1234b" | ./toybox grep -o [0-9]*
/tmp/toybox$
but this does:
/tmp/toybox$ ./toybox grep -o version /proc/version
version
version
as does:
/tmp/toybox$ echo "1234b" | ./toybox grep -o [0-9]*
1234
it seems wrong that there's arithmetic on rm_so/rm_eo before the call to
regexec0() (which will clobber both), and it does seem like the problem is
that we're not getting the right results in rm_so/rm_eo on exit from
regexec0(), but i failed to work out why...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20210212/e912e099/attachment.htm>
More information about the Toybox
mailing list