Bug 34234

Summary: segfault with -x *
Product: Sisyphus Reporter: Ivan Zakharyaschev <imz>
Component: ltraceAssignee: Grigory Ustinov <grenka>
Status: NEW --- QA Contact: qa-sisyphus
Severity: normal    
Priority: P3 CC: grenka, grenka, lav
Version: unstable   
Hardware: all   
OS: Linux   
URL: https://lists.altlinux.org/pipermail/devel-newbies/2017-November/001117.html

Description Ivan Zakharyaschev 2017-11-25 00:36:20 MSK
ltrace crashes when used like this. (The presence of *-debuginfo packages is not essential to reproduce the crash.)

$ ltrace  -x \* /bin/ls /var/empty/
....
<... check_match resumed> ) = { 18799, '\022', '\0', 13, 221008, 220 }
<... do_lookup_x resumed> ) = 1
<... _dl_lookup_symbol_x resumed> ) = <void>
<... _dl_fixup resumed> ) = 140287210082128
getenv@libc.so.6("COLUMNS" <unfinished ...>
strlen@libc.so.6("COLUMNS") = 7
<... getenv resumed> ) = nil
ioctl( <unfinished ...>
--- SIGSEGV (Segmentation fault) ---
+++ killed by SIGSEGV +++

$ ltrace  -x \* /bin/echo a
....
<... check_match resumed> ) = { 20645, '"', '\0', 13, 471424, 151 }
<... do_lookup_x resumed> ) = 1
<... _dl_lookup_symbol_x resumed> ) = <void>
<... _dl_fixup resumed> ) = 140342807331200
fputs_unlocked@libc.so.6(0x7fffa221149b, 0x7fa400007fa4, 45, 32 <unfinished ...>
strlen@libc.so.6("a") = 1
--- SIGSEGV (Segmentation fault) ---
+++ killed by SIGSEGV +++

$ rpm -q ltrace coreutils-debuginfo glibc-core-debuginfo
ltrace-0.7.91.0.198.git82c6640-alt1.x86_64
coreutils-debuginfo-8.27.0.23.f4570-alt1.x86_64
glibc-core-debuginfo-2.25-alt3.x86_64
$

This didn't happen with the previous release:  0.6.0-alt1 

So, this might be the case for git bisect (if someone is interested to catch the bug).
Comment 1 Grigory Ustinov 2018-11-22 17:46:28 MSK
Also crashes on ltrace -x \@ /bin/echo a
and ltrace -x \- /bin/echo a