bug-bash
[Top][All Lists]
Advanced

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

`return' during 'for' while sourcing files


From: Hai Zaar
Subject: `return' during 'for' while sourcing files
Date: Thu, 28 Jul 2005 13:02:48 +0300

Configuration Information [Automatically generated, do not change]:
Machine: i386
OS: linux-gnu
Compiler: i386-pc-linux-gnu-gcc
Compilation CFLAGS:  -DPROGRAM='bash' -DCONF_HOSTTYPE='i386'
-DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='i386-pc-linux-gnu'
-DCONF_VENDOR='pc' -DLOCALEDIR='/usr/share/locale' -DPACKAGE='bash'
-DSHELL -DHAVE_CONFIG_H  -I.  -I. -I./include -I./lib   -O2
-march=pentium4 -pipe
uname output: Linux gentoo 2.6.12-gentoo-r6 #1 SMP Thu Jul 21 16:33:01
Local time zone must be set--see zic  i686 Intel(R) Xeon(TM) CPU
3.60GHz GenuineIntel GNU/Linux
Machine Type: i386-pc-linux-gnu

Bash Version: 3.0
Patch Level: 16
Release Status: release

Description:
        `source'ing file that has `for' loop and using `return' from the loop,
        followed by running log run job (like sleep 10 or xlogo) and
suspending it,
        causes shell to completely missbehave.

Repeat-By:
        Here is the the simple way to reproduce the bug:
        #> cat sourceme <<EOF
        for i in 1 2 3; do
                return
        done
        EOF
        #> source sourceme
        #> sleep 10             # run any long run command
        <hit Ctrl-Z>            # now suspend it
        [1]+  Stopped                 sleep 10
        #> ls /                 # type any command - just nothing will happen
        #> asfasdf

        I've verified this bug also on vanilla bash-3.0. And vanilla bash-3.0
        with LFS patches.




reply via email to

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