On 2016-07-15 at 20:34 Dan Cross <[email protected]> wrote:
> That's very odd. Just adding bash shouldn't remove /bin/ash (which on your
> setup should point to busybox, no?): So invoking the script with /bin/ash
> as the command interpreter should result in you seeing no functional
> changes.
>
> I'll poke at it on Monday.
Here's a simple script that recreates the problem.
---------------------
#!/bin/bash
# uncomment this, and it works as expected.
#echo "$# args"
if [ $# -lt 2 ]
then
echo "$# args is less than 2"
else
echo "$# args is not less than 2"
fi
---------------------
example output:
bash-4.3$ ./args.sh 1 2 3
3 args is not less than 2
bash-4.3$ ./args.sh 1 2 3
3 args is less than 2
- if you uncomment the echo of $#, the 'if' test works as expected.
- the first time you run it in a bash session, it works as expected.
- if you run it on linux, (bash 4.3.11(1)-release), it works as
expected.
barret
--
You received this message because you are subscribed to the Google Groups
"Akaros" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/d/optout.