On Mon, Oct 13, 2025 at 3:01 PM <c...@free.fr> wrote:
>
> Hi,
> reporting unexpected behaviour of bb, moreprecisely it's arithmetic ternary 
> operator.

Yes, the ternary operator had a few bugs.

> This caused me quite a apin to debug my scripts as it was not exactly 
> consistent.
> I join two scripts showcasing the two situations i'm refering to.
> I only got hand on a static build 1.35 for x86-64 but i'm ready to test with 
> more recent build... in an official repository :-)
> the scripts are :
>
>   - ari : show the *leaking* of the execution from 1st case to 2nd case 
> whenever 1st case should be the only outcome.
>            for ref. after i then run the same code under bash giving the 
> expected result
>
>   - tri : simpler yet more puzzling since the code at 1st return erronous 
> result with the actual names i'd give my variables
>           but, strangly for me, changes its outcome in the course of this 
> little sript returning '1' instead of '0' for
>           the SAME set of variables+values ( an actual copy-paste of the 
> initial lines! ).
>           This time both busybox's sh and bash give the same result : I'm 
> really getting to old and refuse change?

I tested both cases in current git and both work correctly (the
results are the same as in bash).
_______________________________________________
busybox mailing list
busybox@busybox.net
https://lists.busybox.net/mailman/listinfo/busybox

Reply via email to