bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Arm machine does not execute background statement correctly


From: Pierre Gaston
Subject: Re: Arm machine does not execute background statement correctly
Date: Wed, 28 Feb 2018 16:15:46 +0200

On Wed, Feb 28, 2018 at 4:03 PM, Chet Ramey <address@hidden> wrote:

> On 2/28/18 5:31 AM, Lakshman Garlapati wrote:
>
> > The following snippet is working fine in x86 processor machine not
> working
> > in arm processor machine from bash 4.3 version onwards.
> >
> > test.sh
> > =====
> > #!/bin/bash
> > rm out.txt
> > function abc() {
> >   if [ 2 -eq 1 ]; then
> >     echo "TRUE"
> >   else
> >     echo "FALSE"
> >   fi
> > }
> > abc &
> >
> > bash -x test.sh
> > ===========
> > + rm -f out.txt
> > + abc
> > + '[' 2 -eq 1 ']'
> > + echo TRUE  <---- Here we are expecting FALSE
> > TRUE
> >
> > please provide some guidance on how to resolve the problem, let me know
> if
> > problem statement is not clear.
>
> I can't reproduce it and don't have a good idea about what might be going
> wrong on your system. Is the arm version compiled with job control enabled?
>
> --
> ``The lyf so short, the craft so long to lerne.'' - Chaucer
>                  ``Ars longa, vita brevis'' - Hippocrates
> Chet Ramey, UTech, CWRU    address@hidden    http://tiswww.cwru.edu/~chet/
>
>
I cannot reproduce it either (on an arm machine)

$ bash -x test.sh
[2]+echo '4.3.30(1)-release'
4.3.30(1)-release
[3]+uname -m
armv7l
[4]+rm out.txt
rm: cannot remove 'out.txt': No such file or directory
[12]+abc
$ [6]+'[' 2 -eq 1 ']'
[9]+echo FALSE
FALSE


reply via email to

[Prev in Thread] Current Thread [Next in Thread]