[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug or feature? Ctrl+C sometimes can't interrupt a loop with multiple en
From: |
Ilya Basin |
Subject: |
bug or feature? Ctrl+C sometimes can't interrupt a loop with multiple enclosed pipes |
Date: |
Mon, 28 Jun 2010 17:06:23 +0400 |
Configuration Information [Automatically generated, do not change]:
Machine: i686
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='i686'
-DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='i686-pc-linux-gnu'
-DCONF_VENDOR='pc' -DLOCALEDIR='/usr/share/locale' -DPACKAGE='bash' -DSHELL
-DHAVE_CONFIG_H -I. -I. -I./include -I./lib -march=i686 -mtune=generic -O2
-pipe
uname output: Linux IL 2.6.33-ARCH #1 SMP PREEMPT Thu May 13 12:06:25 CEST 2010
i686 Intel(R) Core(TM)2 Duo CPU E6550 @ 2.33GHz GenuineIntel GNU/Linux
Machine Type: i686-pc-linux-gnu
Bash Version: 4.1
Patch Level: 7
Release Status: release
Description:
Sample script included.
When I press Ctrl+C, only the inside loop is interrupted. The outside loop
keeps going.
In zsh and in old plain sh Ctrl+C works.
Repeat-By:
run this sample script and try to interrupt it with Ctrl+C:
#########################
{ echo 1; echo 2; echo 3; } | while read a; do
echo $a
{ echo 1; echo 2; echo 3; } | while read b; do
echo $a-$b
sleep 1
done
done
#########################
- bug or feature? Ctrl+C sometimes can't interrupt a loop with multiple enclosed pipes,
Ilya Basin <=