[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Segfault when SIGPIPE and SIGINT used together
From: |
ANDERSON, CRAIG |
Subject: |
Segfault when SIGPIPE and SIGINT used together |
Date: |
Fri, 6 Oct 2017 22:58:35 +0000 |
From: craig.anderson@att.com<mailto:craig.anderson@att.com>
To: bug-bash@gnu.org<mailto:bug-bash@gnu.org>
Subject: Segfault when SIGPIPE and SIGINT used together
Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64'
-DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-unknown-linux-gnu'
-DCONF_VENDOR='unknown' -DLOCALEDIR='/usr/local/share/locale' -DPACKAGE='bash'
-DSHELL -DHAVE_CONFIG_H $IG_H -I. -I. -I./include -I./lib -g -O2
-Wno-parentheses -Wno-format-security
uname output: Linux devbox1 4.4.0-96-generic #119-Ubuntu SMP Tue Sep 12
14:59:54 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Machine Type: x86_64-unknown-linux-gnu
Bash Version: 4.4
Patch Level: 0
Release Status: release
Description:
Bash throws a segfault when it receives a SIGINT under certain
conditions (see "repeat-by" section). dmesg log shows some amount of variance
when the script is run:
[23278.896860] bash[22399]: segfault at 7ffdc2ea5fa8 ip 00000000004c5e99 sp
00007ffdc2ea5fb0 error 6 in bash[400000+102000]
[23446.794155] bash[23110]: segfault at 7ffe4e1fef98 ip 00000000004b9809 sp
00007ffe4e1fefa0 error 6 in bash[400000+f4000]
[23538.683797] bash[23610]: segfault at 7ffe4e1fef98 ip 00000000004b9809 sp
00007ffe4e1fefa0 error 6 in bash[400000+f4000]
[24859.716574] bash[29614]: segfault at 7ffe0c51dff8 ip 00007fa30e104e98 sp
00007ffe0c51e000 error 6 in
libc-2.23.so<http://libc-2.23.so/>[7fa30e058000+1c0000]
[24934.402001] bash[29838]: segfault at 7ffdfc5bafd4 ip 000000000042bd2c sp
00007ffdfc5bafc0 error 6 in bash[400000+102000]
[24946.273217] bash[29889]: segfault at 7ffda7dedff8 ip 00007f8a792d279a sp
00007ffda7dee000 error 6 in
libc-2.23.so<http://libc-2.23.so/>[7f8a792ac000+1c0000]
[24950.338464] bash[29898]: segfault at 7fffb81cfff8 ip 0000000000423612 sp
00007fffb81d0000 error 6 in bash[400000+102000]
[24954.350249] bash[29922]: segfault at 7ffcd44d7fd8 ip 00007ffaa2b387ab sp
00007ffcd44d7fc0 error 6 in
libc-2.23.so<http://libc-2.23.so/>[7ffaa2b12000+1c0000]
[24957.479164] bash[29956]: segfault at 7ffd695a0fa8 ip 00007f73a1e0f7ab sp
00007ffd695a0f90 error 6 in
libc-2.23.so<http://libc-2.23.so/>[7f73a1de9000+1c0000]
[25014.715412] bash[30181]: segfault at 7ffcde19cfc4 ip 000000000042bd2c sp
00007ffcde19cfb0 error 6 in bash[400000+102000]
[25021.565213] bash[30232]: segfault at 7ffc973c7ff8 ip 0000000000425798 sp
00007ffc973c8000 error 6 in bash[400000+102000]
Repeat-By:
Running the following script:
#!/bin/bash
exec >& >(while read line; do echo "$line"; done)
trap 'echo sigpipe' SIGPIPE
trap 'echo sigint' SIGINT
echo 'Sleeping 60 seconds, press Ctrl+C to segfault!'
sleep 60
- Segfault when SIGPIPE and SIGINT used together,
ANDERSON, CRAIG <=