Re: Bug in test [ $n != 0 ]; then

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

 



On Sat, 12 Jun 2004 11:07:40 -0600
clemens@xxxxxxx wrote:

> I have a script here that ran fine up thru Fc2T1, but 
> test (I assume) is now complaining.
> 
> The error is:
>     ./update2.sh: line 126: [: too many arguments
> 
> The line in question is:
>     if [ $n9 -ne 0 ]; then
> 
> I tried ${n9} but got the same error.
> 
> I dont see any error, and it has worked up to now, anyone else
> see a problem?

Reg,

Likely $n9 is being expanded to something with a whitespace in it
and then being interpreted as multiple arguments, try:

if [ "$n9" -ne 0 ]; then

Cheers,
Sean



[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux