Martijn Dekker dixit:

> I noticed something strange while executing some 'eval'-ed commands: the -e/-o
> errexit appears to become active out of nowhere.
>
> $ mksh -c 'echo $-; eval '\''echo $-'\''; echo $-'
> hc
> ehc
> hc

Found to be caused by reusing bit7 of the ERREXIT flag for
nefarious purposes; fixed, but we could not get completely
rid of the flag.

> However, both pdksh and mksh render 'set -e' ineffective for eval'ed commands,
> which is a bug in itself; no other shell including ksh93 shares this 
> behaviour.
> Thus the expected output for the last command above is 'hc' and nothing else.

When run under -e of course.

Fixed, this was way harder.

Thanks,
//mirabilos
-- 
This space for rent.

https://paypal.me/mirabilos to support my work.

Reply via email to