[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [patch #7818] Loop breaks when trying to write to a readonly variabl
From: |
Chet Ramey |
Subject: |
Re: [patch #7818] Loop breaks when trying to write to a readonly variable |
Date: |
Fri, 13 Jul 2012 11:28:26 -0400 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:13.0) Gecko/20120614 Thunderbird/13.0.1 |
On 7/13/12 11:17 AM, Daniel Amthor wrote:
> Chet,
>
> 2012/7/13 Chet Ramey <address@hidden <mailto:address@hidden>>
>
> On 7/13/12 8:53 AM, Daniel Amthor wrote:
>
> Yeah, that's an assignment error. Posix says a non-interactive shell
> should exit in that case and that an interactive shell should write an
> error message without exiting. Bash doesn't exit the shell, but it does
> cause the current command to fail.
>
> So...works as designed ?
Yes. I think aborting the shell script is a little drastic, but bash does
it in Posix mode.
Chet
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU address@hidden http://cnswww.cns.cwru.edu/~chet/