[Top][All Lists]

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

Re: bash 4.2, parameter expansion problem

From: Eric Blake
Subject: Re: bash 4.2, parameter expansion problem
Date: Mon, 14 Feb 2011 11:02:47 -0700
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.7

On 02/14/2011 10:51 AM, Juergen Daubert wrote:
> Hello,
> I stumbled over the following while trying to build xterm from sources 
> with bash 4.2:
>  $:~> /bin/sh --version | head -n1
>  GNU bash, version 4.2.0(1)-release (i686-pc-linux-gnu)
>  $:~> /bin/sh
>  sh-4.2$ a="${b:-'/foo/bar'}"
>  sh: bad substitution: no closing `}' in ${b:-'/foo/bar'}
>  sh-4.2$ a="${b:-'bar'}"
>  sh-4.2$ a="${b:-/foo/bar}"
>  sh-4.2$
> looks like bash, when called as sh, doesn't like the / character in 
> single-quoted strings.

Looks like a bug in how bash was modified for trying to obey this new
POSIX rule:


Eric Blake   address@hidden    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

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