[Toybox] Defect in Argument parsing for "#" and "-"
Rob Landley
rob at landley.net
Tue Jul 3 19:26:43 PDT 2012
On 07/02/2012 10:05 PM, Ashwini Sharma wrote:
> I had a case where depth of traversal was to be defined as cmdline argument.
> Giving "kmgtpe" would return zero, whereas I wanted it to only
> integers as argument and no alpha characters.
By the way, that probably _is_ a bug. If you haven't seen a digit yet,
units are useless. I'd have to check what "sleep" and "od" and such
wanted in that case, but I can probably fix it so you need at least
_something_ before a unit. (Of course that opens "- -k" and such, which
depends on what strtol() does with just a minus...)
Rob
--
GNU/Linux isn't: Linux=GPLv2, GNU=GPLv3+, they can't share code.
Either it's "mere aggregation", or a license violation. Pick one.
1341368803.0
More information about the Toybox
mailing list