Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > gnu.bash.bug > #16118
| From | kutay üner <husnukutay@gmail.com> |
|---|---|
| Newsgroups | gnu.bash.bug |
| Subject | SEGFAULT ON TILDE EXPANSION |
| Date | 2020-04-10 17:59 +0300 |
| Message-ID | <mailman.460.1586538065.2644.bug-bash@gnu.org> (permalink) |
| References | <CAF8GSSDEdC-RUhT6iA34HixAZDHBZ0QTegAdPKPoGd+eZT_ZyA@mail.gmail.com> |
Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS: -O0 -ggdb -Wno-parentheses -Wno-format-security
uname output: Linux hk 5.6.3-arch1-1 #9 SMP PREEMPT Thu, 09 Apr 2020
03:39:30 +0000 x86_64 GNU/Linux
Machine Type: x86_64-pc-linux-gnu
Bash Version: 5.0
Patch Level: 16
Release Status: release
Description:
Trying to tab expand a tilde causes segfault. This action requires us to
get user entries by calling getpwent which is provided by
libnss_systemd.so
on my system.
If we compile bash with it's malloc implementation, libraries it depends
on also start to use this version of malloc.
getpwent function in libnss_systemd.so takes advantage of the C malloc
returning max_align_t aligned memory. Bash malloc returns 8 byte
aligned
memory which is less than 16 byte requirement on my x86-64 system. This
is the root cause of segfault.
Repeat-By:
$ echo ~u
Fix:
./configure --without-bash-malloc
Back to gnu.bash.bug | Previous | Next | Find similar
SEGFAULT ON TILDE EXPANSION kutay üner <husnukutay@gmail.com> - 2020-04-10 17:59 +0300
csiph-web