Control: tags 926658 + patch upstream fixed-upstream
Dear Maintainer,
I just tried to help triage this issue.
I think this is related to upstream bug [1] and
was already fixed in the 5.2 branch by commit [2].
A package built with this patch does just show the
'undefined variable' error, but not the double free fault.
Kind regards,
Bernhard
[1] https://sourceforge.net/p/gnuplot/bugs/2115/
[2]
https://sourceforge.net/p/gnuplot/gnuplot-main/ci/732014eefd41235a143626d2bc02d3d34934e1b3/
# Buster amd64 real hardware 2019-04-09
apt update
apt dist-upgrade
#
mkdir /home/benutzer/926658_gnuplot-crash -p
cd/home/benutzer/926658_gnuplot-crash
debootstrap --arch=amd64 buster chroot
http://192.168.178.25:/debian-10-buster-deb.debian.org/
mount --rbind /proc chroot/proc
cp -a ../rr*.deb chroot/
# workaround https://github.com/mozilla/rr/issues/2342
env -i TERM=xterm LANG=de_DE.UTF-8 /usr/sbin/chroot chroot /bin/su -l root
apt install locales
dpkg-reconfigure locales
nano /etc/inputrc
adduser benutzer
mv /etc/apt/sources.list /etc/apt/sources.list.d/buster-approx.list
echo "deb-src http://192.168.178.25:/debian-10-buster-deb.debian.org
buster main" >> /etc/apt/sources.list.d/buster-approx.list
echo "deb
http://192.168.178.25:/debian-10-buster-debug.mirrors.debian.org
buster-debug main" >> /etc/apt/sources.list.d/buster-approx.list
apt update
apt install dpkg-dev devscripts mc wget unzip rr gdb gnuplot
gnuplot-qt-dbgsym
dpkg -i /*.deb
# workaround https://github.com/mozilla/rr/issues/2342
echo 1 > /proc/sys/kernel/perf_event_paranoid
env -i TERM=xterm LANG=de_DE.UTF-8 /usr/sbin/chroot chroot /bin/su -l benutzer
mkdir /home/benutzer/source/gnuplot/orig -p
cd/home/benutzer/source/gnuplot/orig
apt source gnuplot
cd
mkdir /home/benutzer/source/libc6/orig -p
cd/home/benutzer/source/libc6/orig
apt source libc6
cd
wget
"https://bugs.debian.org/cgi-bin/bugreport.cgi?att=1;bug=926658;filename=test-files.zip;msg=10";
-O test-files.zip
unzip test-files.zip
cd test-files
rr record gnuplot call.gpi
rr replay
set width 0
set pagination off
directory
/home/benutzer/source/gnuplot/orig/gnuplot-5.2.6+dfsg1/src/wxterminal/bitmaps
directory /home/benutzer/source/libc6/orig/glibc-2.28/malloc
cont
bt
reverse-finish
reverse-finish
reverse-finish
reverse-finish
reverse-finish
reverse-finish
reverse-finish
print a->v.string_val
print &(a->v.string_val)
b __GI___libc_free if mem==0x564e97351a60
watch *0x564e9734ed90
reverse-cont
bt
reverse-finish
print a->v.string_val
print &(a->v.string_val)
reverse-cont
bt
#
benutzer@willi-laptop:~$ gnuplot --version
gnuplot 5.2 patchlevel 6
benutzer@willi-laptop:~/test-files$ rr record gnuplot call.gpi
rr: Saving execution to trace directory
`/home/benutzer/.local/share/rr/gnuplot-0'.
Plotting $tag statistics...
"./tags.gpi" line 27: undefined variable: date_min
free(): double free detected in tcache 2
Abgebrochen
benutzer@willi-laptop:~/test-files$ rr replay
...
Reading symbols from /usr/bin/gnuplot-qt...(no debugging symbols found)...done.
Really redefine built-in command "restart"? (y or n) [answered Y; input not
from terminal]
Remote debugging using 127.0.0.1:16489
Reading symbols from /lib64/ld-linux-x86-64.so.2...Reading symbols from
/usr/lib/debug/.build-id/75/5312dcb2382eb2fde78494879bb2104028ae80.debug...done.
done.
0x7f088a6fd090 in _start () from /lib64/ld-linux-x86-64.so.2
(rr) set width 0
(rr) set pagination off
(rr) cont
Continuing.
Plotting $tag statistics...
"./tags.gpi" line 27: undefined variable: date_min
free(): double free detected in tcache 2
Program received signal SIGABRT, Aborted.
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
50 ../sysdeps/unix/sysv/linux/raise.c: Datei oder Verzeichnis nicht
gefunden.
(rr) bt
#0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
#1 0x7f0d2535 in __GI_abort () at abort.c:79
#2 0x7f0888929778 in __libc_message (action=action@entry=do_abort,
fmt=fmt@entry=0x7f0888a3428d "%s\n") at ../sysdeps/posix/libc_fatal.c:181
#3 0x7f088892fe6a in malloc_printerr (str=str@entry=0x7f0888a35f58
"free(): double free detected in tcache 2") at malloc.c:5341
#4 0x7f088893194d in _int_free (av=0x7f0888a6bc40 ,
p=0x564e97351a50, have_lock=) at malloc.c:4193
#5 0x564e95fbb8bd in ?? ()
#6 0x564e95fbbd6b in ?? ()
#7 0x564e95fec887 in ?? ()
#8 0x564e95fece8d in ?? ()
#9 0x564e95f9b3bd in ?? ()
#10 0x7f0d409b in __libc_start_main (main=0x564e95f9b000, argc=2,
argv=0x7ffe67c3fb68, init=, fini=,
rtld_fini=, stack_end=0x7ffe67c3fb58) at ../csu/libc-start.c:308
#11 0x564e95f9c76a in ?? ()
# With debug symbols
benutzer@willi-laptop:~$ rr replay
GNU gdb (Debian 8.2.1-2) 8.2.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GP