Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 435732 - x11-terms/rxvt-unicode-9.15 - glibc detected *** urxvtd: malloc(): smallbin double linked list corrupted: in rxvt_display8flush
Summary: x11-terms/rxvt-unicode-9.15 - glibc detected *** urxvtd: malloc(): smallbin d...
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-09-21 11:38 UTC by tristanC
Modified: 2020-12-07 17:14 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
The complete traceback (urxvtd_stacktrace.txt,6.03 KB, text/plain)
2012-09-21 11:39 UTC, tristanC
Details
Another trace (urxvtd_stacktrace2.txt,22.10 KB, text/plain)
2012-09-21 12:15 UTC, tristanC
Details
gdb backtrace (gdb.txt,2.81 KB, text/plain)
2013-04-21 03:16 UTC, Homer
Details
gdb backtrace (corrupted double-linked list) (urxvtd-corrupted-double-linked-list.gdb.txt,17.39 KB, text/plain)
2013-04-21 03:49 UTC, Homer
Details
gdb backtrace (segfault) (urxvtd-segfault.gdb.txt,8.20 KB, text/plain)
2013-04-21 04:04 UTC, Homer
Details

Note You need to log in before you can comment on or make changes to this bug.
Description tristanC 2012-09-21 11:38:36 UTC
Some keystrockes in an urxvtc client make the server crash. I still can't say what exactly trigger the bug, it only happened once or twice a day.

The standalone version (urxvt) doesn't look affected so far.

Reproducible: Always

Steps to Reproduce:
1. Launch urxvtd -q -o -f
2. Launch some urxvtc client
3. Use client until they crash...
Actual Results:  
The server crash with "*** glibc detected *** urxvtd: malloc(): smallbin double linked list corrupted: 0x00000000026cf3b0 ***"
and all clients windows silently exit, killing all attached processes



Kernel: vanilal from kernel.org, linux 3.4.10, x86_64.
Windows manager: Awesome on nvidia-drivers.
unicode

Portage 2.3.4-r9 (funtoo/1.0/linux-gnu/arch/x86-64bit, gcc-4.6.2, glibc-2.13-r4, 3.4.10 x86_64)
=================================================================
System uname: Linux-3.4.10-x86_64-Intel-R-_Core-TM-_i5-2400_CPU_@_3.10GHz-with-gentoo-2.2.0
Timestamp of tree: Fri, 21 Sep 2012 05:45:01 +0000
app-shells/bash:          4.2_p37
dev-java/java-config:     2.1.12-r1000
dev-lang/python:          2.7.3-r1000, 3.2.3-r1000
dev-util/cmake:           2.8.7-r5
dev-util/pkgconfig:       0.27.1
sys-apps/baselayout:      2.2.0-r1
sys-apps/openrc:          0.10.2-r5
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.68
sys-devel/automake:       1.11.6
sys-devel/binutils:       2.21.1-r1
sys-devel/gcc:            4.6.2
sys-devel/gcc-config:     1.5-r1
sys-devel/libtool:        2.4-r4
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 2.6.39 (virtual/os-headers)
sys-libs/glibc:           2.13-r4
Repositories: gentoo
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/lib/hsqldb /var/qmail/alias /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/apache2-php5.4/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cgi-php5.4/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/php/cli-php5.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-march=native -O2 -pipe"
DISTDIR="/home/install/distfiles"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles mini-manifest news parallel-fetch parse-eapi-ebuild-head preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS=""
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed"
LINGUAS="fr en"
MAKEOPTS="-j5"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="git://github.com/funtoo/ports-2012.git"
SYNC_USER="root"
USE="aalib aio alsa amd64 berkdb blink bzip2 cairo cracklib crypt cscope cxx ffmpeg fftw flac ftp g3dvl gdbm gif iconv jack jpeg kvm lcdfilter libcaca mad mmx modules mp3 mudflap multilib ncurses nptl ogg opengl openmp oss pam pcre png rar readline sdl session sndfile spell sqlite sse sse2 ssl ssse3 tcpd tiff truetype unicode vdpau vim-syntax vorbis xcb xml zlib" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="fr en" PHP_TARGETS="php5-3" PYTHON_ABIS="2.7 3.2" PYTHON_TARGETS="python2_7" QEMU_SOFTMMU_TARGETS="x86_64 i386" RUBY_TARGETS="ruby18 ruby19" USERLAND="GNU" VIDEO_CARDS="nv vesa" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, SYNC_UMASK

=================================================================
                        Package Settings
=================================================================

x11-terms/rxvt-unicode-9.15 was built with the following:
USE="256-color afterimage blink focused-urgency font-styles mousewheel (multilib) perl vanilla xft -alt-font-width -buffer-on-clear -fading-colors -iso14755 -pixbuf -secondary-wheel -startup-notification -unicode3 -wcwidth"
Comment 1 tristanC 2012-09-21 11:39:54 UTC
Created attachment 324492 [details]
The complete traceback
Comment 2 tristanC 2012-09-21 12:15:12 UTC
Created attachment 324498 [details]
Another trace
Comment 3 tristanC 2012-09-21 12:15:51 UTC
Second trace happened on urxvtc creation
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2012-09-21 15:40:48 UTC
A real gdb backtrace would be nice.
Comment 5 tristanC 2012-09-24 09:35:58 UTC
It seems that urxvtd catchs the SIGSEGV signal as it doesn't generate a coredump on crash when ran in an "ulimit -c unlimited" session.

Gdb isn't practical as everytime a client connect it interrupts with 
"Program received signal SIGPIPE, Broken pipe."

How should I produce a real gdb backtrace ?
Comment 6 Jeroen Roovers (RETIRED) gentoo-dev 2012-09-24 11:44:45 UTC
(In reply to comment #5)
> It seems that urxvtd catchs the SIGSEGV signal as it doesn't generate a
> coredump on crash when ran in an "ulimit -c unlimited" session.
> 
> Gdb isn't practical as everytime a client connect it interrupts with 
> "Program received signal SIGPIPE, Broken pipe."
> 
> How should I produce a real gdb backtrace ?

http://www.gentoo.org/proj/en/qa/backtraces.xml

1) ulimit -c unlimited
2) [start urxvtd]
3) Wait for the crash. Locate the `core' file containing the core dump.
4) Run gdb /usr/bin/urxvtd [path to core dump]
5) Enter something like `thread apply all backtrace full' in gdb.
Comment 7 avx 2012-10-07 02:40:49 UTC
I'm experiencing crashes of urxvtd, too. Can't reproduce it, sometimes my shortcut to spawn urxvtc just results in nothing.

emerge --info rxvt-unicode
Portage 2.1.11.21 (default/linux/amd64/10.0/desktop, gcc-4.6.3, glibc-2.15-r2, 3.5.3-gentoo x86_64)
=================================================================
                        System Settings
=================================================================
System uname: Linux-3.5.3-gentoo-x86_64-Intel-R-_Core-TM-_i7_CPU_920_@_2.67GHz-with-gentoo-2.2
Timestamp of tree: Tue, 02 Oct 2012 21:45:01 +0000
app-shells/bash:          4.2_p37
dev-java/java-config:     2.1.12
dev-lang/python:          2.7.3-r2, 3.2.3-r1
dev-util/cmake:           2.8.9
dev-util/pkgconfig:       0.27.1
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.10.5
sys-apps/sandbox:         2.6
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.4_p6-r1, 1.7.9-r2, 1.11.6, 1.12.4
sys-devel/binutils:       2.22.90
sys-devel/gcc:            4.6.3
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 3.5 (virtual/os-headers)
sys-libs/glibc:           2.15-r2
Repositories: gentoo enlightenment vmware desktop-effects x-yubikey
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -mtune=native -msse4 -mcx16 -msahf -mpopcnt -O2 -pipe -fomit-frame-pointer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminf
CXXFLAGS="-march=native -mtune=native -msse4 -mcx16 -msahf -mpopcnt -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="ftp://sunsite.informatik.rwth-aachen.de/pub/Linux/gentoo http://distfiles.gentoo.org"
LANG="de_DE.utf8"
LDFLAGS="-Wl,--hash-style=gnu -Wl,-O1 -Wl,--as-needed -Wl,--sort-common"
LINGUAS="de de_DE en en_US"
MAKEOPTS="-j9 --quiet"
PKGDIR="/usr/portage/packages"
PORTAGE_COMPRESS="xz"
PORTAGE_COMPRESS_FLAGS="-9"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTDIR="/usr/portage/gentoo"
PORTDIR_OVERLAY="/var/lib/layman/enlightenment /var/lib/layman/vmware /var/lib/layman/desktop-effects /usr/portage/yubikey"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa amd64 berkdb bluetooth branding bzip2 cairo cdda cdr cli consolekit cracklib crypt cups cxx dbus dri dts dvd dvdr emboss encode exif fam firefox flac fortran gdbm gif gpm gtk iconv ipv6 jpeg lcms ldap libnotify mad mmx mng modules mp3 mp4 mpeg mudflap multilib ncurses nls nptl ogg opengl openmp pam pango pcre pdf png policykit ppds pppd qt3support qt4 readline sdl session spell sse sse2 ssl startup-notification svg tcpd tiff truetype udev udisks unicode upower usb vorbis wxwidgets x264 xcb xml xv xvid zlib" ALSA_CARDS="hda-intel" ALSA_PCM_PLUGINS="*" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="casio_qv" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev joystick wacom" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="de de_DE en en_US" PHP_TARGETS="php5-3" PYTHON_TARGETS="python3_2 python2_7" RUBY_TARGETS="ruby18 ruby19" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
USE_PYTHON="2.7 3.2"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_RSYNC_EXTRA_OPTS

=================================================================
                        Package Settings
=================================================================

x11-terms/rxvt-unicode-9.15-r1 was built with the following:
USE="256-color mousewheel (multilib) perl secondary-wheel startup-notification wcwidth xft -afterimage -alt-font-width -blink -buffer-on-clear -fading-colors -focused-urgency -font-styles -iso14755 -pixbuf -unicode3 -vanilla"
Comment 8 Mitch Harder 2013-01-05 22:08:43 UTC
I had also been getting crashes of my urxvtd process.

Sometimes I would get an error as listed in the main topic, other times it would be a plain segfault.

In my case, it was related to building with infinality font configuration.

Since I rebuilt media-libs/freetype without the 'infinality' USE flag, and depcleaned the infinality packages, I've been unable to reproduce the error.
Comment 9 Homer 2013-04-05 01:32:53 UTC
+1

I can also confirm this definitely seems linked to the Infinality patch.

I've continually experienced this bug on one system with the Infinality patch, but had no issues on another system without it for over a year, until I re-emerged media-libs/freetype with USE="infinality" two days ago, and since then urxvtd has been alternately bombing with a "malloc(): smallbin double linked list corrupted" error or a simple segfault.

I didn't make the connection until I read the bug reports here and on Arch:

https://bbs.archlinux.org/viewtopic.php?id=156748
Comment 10 Jeroen Roovers (RETIRED) gentoo-dev 2013-04-06 17:05:19 UTC
Could someone seeing this problem attach an actual gdb backtrace, please?
Comment 11 Homer 2013-04-21 03:16:47 UTC
Created attachment 346142 [details]
gdb backtrace

Hope this helps.
Comment 12 Homer 2013-04-21 03:49:07 UTC
Created attachment 346144 [details]
gdb backtrace (corrupted double-linked list)

Sorry, that last backtrace wasn't very informative.
New trace with stack frames dump.
Comment 13 Homer 2013-04-21 04:04:52 UTC
Created attachment 346146 [details]
gdb backtrace (segfault)

Same again, but this time caused by a segfault.
(This seems to happen alternately with the corrupted double linked list error.)

Just to reiterate: these two errors occur when closing the urxvtc client, but not every time. It seems to be every third window that's opened and closed that causes one of the above two errors (in fact I just checked, and it's exactly every third window, reproducible every time).
Comment 14 Homer 2013-04-21 04:23:58 UTC
(In reply to comment #5)
> It seems that urxvtd catchs the SIGSEGV signal as it doesn't generate a
> coredump on crash when ran in an "ulimit -c unlimited" session.
> 
> Gdb isn't practical as everytime a client connect it interrupts with 
> "Program received signal SIGPIPE, Broken pipe."
> 
> How should I produce a real gdb backtrace ?

Use either "handle SIGPIPE nostop" before running, or "continue" at SIGPIPE (repeatedly if necessary).
Comment 15 tristanC 2013-07-03 12:17:00 UTC
Hi,

I haven't experienced any urxvtd crash since a long time.
Currently running x11-terms/rxvt-unicode-9.18 with the same USE flags.

Maybe it is time to mark this bug resolved ?
Comment 16 Homer 2013-12-10 08:27:24 UTC
Just to confirm I still get this crash with 9.18 and 9.19, except now the daemon crashes every time a client exits, not just every third time, with the same error "segmentation fault".

Has upstream (schmorpforge[AT]schmorp.de) been notified?
Comment 17 Jeroen Roovers (RETIRED) gentoo-dev 2013-12-10 10:18:29 UTC
(In reply to Homer from comment #16)
> Has upstream (schmorpforge[AT]schmorp.de) been notified?

If you do, make sure you have USE=vanilla.
Comment 18 Homer 2013-12-12 03:09:56 UTC
I just rebuilt with USE="vanilla" and no other flags (defaults), and urxvtd still bombs when the client exits, with:

glibc detected *** urxvtd: malloc(): smallbin double linked list corrupted: 0x00000000019a6c70

I've also left a message on upstream's IRC channel.
Comment 19 Ewgenij Starostin 2014-09-15 06:46:48 UTC
This was a bug in the infinality patchset for Freetype, which now may have been fixed upstream:
https://github.com/bohoomil/fontconfig-ultimate/issues/43
Comment 20 Marek Szuba archtester gentoo-dev 2020-12-07 17:14:58 UTC
Version long gone from the tree (and according to the comments this might have been a fontconfig problem in the end).