[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: error in globash.rc
From: |
Shigio Yamaguchi |
Subject: |
Re: error in globash.rc |
Date: |
Fri, 01 Feb 2002 08:13:56 +0900 |
Hello,
> The check for bash version in globash.rc of global-4.3.1 (but the same
> bug is in version 4.1.1) fails if BASH_VERSINFO[1] contains letters.
> I have bash version 2.05a.0(1)-release, and I get:
>
> address@hidden:~/local/src/global-4.3.1$ bash --rcfile globash.rc
> bash: 05a: value too great for base (error token is "05a")
> Segmentation fault
>
>
> The following patch should fix the problem:
>
>
> --- globash.rc Tue Jan 22 07:30:59 2002
> +++ globash.rc-new Thu Jan 31 19:13:14 2002
> @@ -27,10 +27,12 @@
> # $ bash --rcfile <this file>
> # [/usr/src/sys] ghelp<RET>
> #
> -if !(( BASH_VERSINFO[0] >= 2 && BASH_VERSINFO[1] >= 4 )); then
> +bash_minorversion=$(echo ${BASH_VERSINFO[1]} | sed 's/[[:alpha:]]//')
> +if !(( BASH_VERSINFO[0] >= 2 && bash_minorversion >= 4 )); then
> echo "GloBash needs Bash version 2.04 or later."
> exit 1
> fi
> +unset bash_minorversion
> ###########################################################################
> # Global variables and utilities.
> ###########################################################################
Fixed. Thank you!
--
Shigio Yamaguchi - Tama Communications Corporation