Hello!
> > expr a : '\(a\)'
> > echo $?
> > b=`expr a : '\(a\)'`
> > echo $b,$?
> >
> > Gives:
> >
> > a
> > 1
> > a,0
David, could you please test this:
b=`false` || echo Ok
It should print "Ok". If it doesn't, we are in trouble.
> Sorry, I was already inefficient I guess. It's the same bug as ASh's
> one reported by Pavel.
It's a different bug. With ash, you shouldn't rely on $? after assignments
_unless_ backticks are used. In this case, you cannot rely on $? _if_
backticks are used.
Unfortunately, the later is hard to eliminate. There are many constructs
of this kind in config.status, e.g.
ac_file_inputs=`IFS=:
for f in $ac_file_in; do
...
esac
done` || { false; exit; }
I'm afraid that Autoconf will have to reject QNX's shell. It's hard to
work around this kind of shell braindamage :-(
Regards,
Pavel Roskin
- expr ... and `expr ...` return different results on QNX 4.2.... David Morgan
- Re: expr ... and `expr ...` return different results on... akim
- Re: expr ... and `expr ...` return different result... Akim Demaille
- FYI: Reading the $? of an assignment (Was: expr ... and... Pavel Roskin
- FYI: Reading the $? of an assignment (Was: expr ...... Akim Demaille
- Re: expr ... and `expr ...` return different results on... David Morgan
- Re: expr ... and `expr ...` return different results on... Pavel Roskin
- Re: expr ... and `expr ...` return different results on... Akim Demaille
- Re: expr ... and `expr ...` return different results on... Lars J. Aas
- Re: expr ... and `expr ...` return different results on... Paul Eggert
- Re: expr ... and `expr ...` return different results on... Pavel Roskin
- Re: expr ... and `expr ...` return different result... Akim Demaille
- Re: expr ... and `expr ...` return different results on... Lars J. Aas
