bug-bash
[Top][All Lists]
Advanced

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

Re: . (source) builtin behavior changed when commands are in {} braces


From: Roman Rakus
Subject: Re: . (source) builtin behavior changed when commands are in {} braces
Date: Sun, 17 Aug 2008 23:57:16 +0200
User-agent: Thunderbird 2.0.0.16 (X11/20080723)

Chet Ramey wrote:
Roman Rakus wrote:
In previous version (3.0) bash continue after {} braces.
For example:
{
 readonly a
 a=10
} || :

echo hello


In bash 3.2 we've got error message about readonly variable, but "hello" is not printed. Is this right behavior or bug?

I'm not sure what changes you've made to the red hat version of bash, but
bash-3.2.17 and bash-3.2.39 (the two versions I happen to have on this
machine) both print `hello' after the error message. The top_level_cleanup
function and the calls to it were introduced in bash-3.2 patch 20, so
the behavior appears to be consistent before and after the patch.

Chet

It's strange. Now I build bash with only official patches. Version 3.2.39. Hello isn't printed. If I don't use patch 20, then Hello is printed. I'm using this command:
./bash -c ". ~/tmp/bash/braces/test.sh"


Did you use . builtin?




reply via email to

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