Irssi core bugs

Notice: Undefined index: tasklist_type in /var/www/bugs.irssi.org/includes/class.tpl.php(128) : eval()'d code on line 85 Notice: Undefined index: tasklist_type in /var/www/bugs.irssi.org/includes/class.tpl.php(128) : eval()'d code on line 90
  • Status New
  • Percent Complete
    0%
  • Task Type Bug Report
  • Category core
  • Assigned To No-one
  • Operating System Linux
  • Severity Medium
  • Priority Normal
  • Reported Version Irssi SVN
  • Due in Version Undecided
  • Due Date Undecided
  • Votes 0
  • Private No
Attached to Project: Irssi core bugs
Opened by David (phyber) - 2006-07-28
Last edited by Emanuele Giaquinta (ayin) - 2008-03-14

FS#440 - irssi core dump when compiled --with-gc

This only started happening recently, I've tried upgrading and downgrading gc but end up with the same results.
This dump is one where I compiled irssi against gc-6.8.

#0 0xb7c92adc in GC_free () from /usr/local/lib/libgc.so.1
#1 0xb7e57d61 in g_free () from /usr/lib/libglib-2.0.so.0
#2 0xb7e43e94 in g_hash_table_unref () from /usr/lib/libglib-2.0.so.0
#3 0xb7e43f35 in g_hash_table_destroy () from /usr/lib/libglib-2.0.so.0
#4 0x080e0ba8 in config_close (rec=0x81f32d0) at parse.c:339
#5 0xb7e675af in g_slist_foreach () from /usr/lib/libglib-2.0.so.0
#6 0x080a3330 in theme_register_module (module=0x81a39f1 "fe-common/core", formats=0x81c89a0) at themes.c:735
#7 0x08091359 in fe_common_core_init () at fe-common-core.c:185
#8 0x0807f9dd in main (argc=1, argv=0xbfbe4c74) at irssi.c:152
(gdb) bt full
#0 0xb7c92adc in GC_free () from /usr/local/lib/libgc.so.1
No symbol table info available.
#1 0xb7e57d61 in g_free () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#2 0xb7e43e94 in g_hash_table_unref () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#3 0xb7e43f35 in g_hash_table_destroy () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#4 0x080e0ba8 in config_close (rec=0x81f32d0) at parse.c:339
__PRETTY_FUNCTION__ = "config_close"
#5 0xb7e675af in g_slist_foreach () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#6 0x080a3330 in theme_register_module (module=0x81a39f1 "fe-common/core", formats=0x81c89a0) at themes.c:735
No locals.
#7 0x08091359 in fe_common_core_init () at fe-common-core.c:185
version_options = {{longName = 0x0, shortName = 0 '\0', argInfo = 5, arg = 0x80910b0, val = 0, descrip = 0x0, argDescrip = 0x0}, {longName = 0x81a3d64 "version", shortName = 118 'v', argInfo = 0,
arg = 0x0, val = 0, descrip = 0x81a6377 "Display irssi version", argDescrip = 0x0}, {longName = 0x0, shortName = 0 '\0', argInfo = 0, arg = 0x0, val = 0, descrip = 0x0, argDescrip = 0x0}}
options = {{longName = 0x0, shortName = 0 '\0', argInfo = 4, arg = 0x81c87e0, val = 0, descrip = 0x0, argDescrip = 0x0}, {longName = 0x0, shortName = 0 '\0', argInfo = 4, arg = 0x81cb920, val = 0,
descrip = 0x81a638d "Help options", argDescrip = 0x0}, {longName = 0x81a5e4d "connect", shortName = 99 'c', argInfo = 1, arg = 0x81d596c, val = 0,
descrip = 0x81a653c "Automatically connect to server/network", argDescrip = 0x81a22ca "SERVER"}, {longName = 0x81a63a6 "password", shortName = 119 'w', argInfo = 1, arg = 0x81d5970, val = 0,
descrip = 0x81a639a "Autoconnect password", argDescrip = 0x81a63af "PASSWORD"}, {longName = 0x81a63c4 "port", shortName = 112 'p', argInfo = 2, arg = 0x81d5974, val = 0,
descrip = 0x81a63b8 "Autoconnect port", argDescrip = 0x81bc074 "PORT"}, {longName = 0x81a63c9 "noconnect", shortName = 33 '!', argInfo = 0, arg = 0x81d5978, val = 0,
descrip = 0x81a63d3 "Disable autoconnecting", argDescrip = 0x0}, {longName = 0x81a3f73 "nick", shortName = 110 'n', argInfo = 1, arg = 0x81d597c, val = 0, descrip = 0x81a63ea "Specify nick to use",
argDescrip = 0x0}, {longName = 0x81a22fc "hostname", shortName = 104 'h', argInfo = 1, arg = 0x81d5980, val = 0, descrip = 0x81a63fe "Specify host name to use", argDescrip = 0x0}, {longName = 0x0,
shortName = 0 '\0', argInfo = 0, arg = 0x0, val = 0, descrip = 0x0, argDescrip = 0x0}}
#8 0x0807f9dd in main (argc=1, argv=0xbfbe4c74) at irssi.c:152
options = {{longName = 0x81a1944 "dummy", shortName = 100 'd', argInfo = 0, arg = 0x81d58dc, val = 0, descrip = 0x81a194a "Use the dummy terminal mode", argDescrip = 0x0}, {longName = 0x0,
shortName = 0 '\0', argInfo = 0, arg = 0x0, val = 0, descrip = 0x0, argDescrip = 0x0}}

This task does not depend on any other tasks.

Ray Van Dolson (rayvd)
Wednesday, 01 August 2007, 17:03 GMT
Also confirmed...

<pre>
[root@arthur ~]# gdb irssi
GNU gdb Red Hat Linux (6.3.0.0-1.143.el4rh)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux-gnu"...Using host libthread_db library "/lib/tls/libthread_db.so.1".

(gdb) r
Starting program: /usr/bin/irssi
[Thread debugging using libthread_db enabled]
[New Thread -1208432416 (LWP 14914)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1208432416 (LWP 14914)]
0x0090acf5 in GC_malloc (bytes=52) at thread_local_alloc.c:176
176 thread_local_alloc.c: No such file or directory.
in thread_local_alloc.c
(gdb) bt
#0 0x0090acf5 in GC_malloc (bytes=52) at thread_local_alloc.c:176
#1 0x002ee963 in g_malloc () from /usr/lib/libglib-2.0.so.0
#2 0x002ef4c7 in g_mem_chunk_new () from /usr/lib/libglib-2.0.so.0
#3 0x002d2154 in g_array_sized_new () from /usr/lib/libglib-2.0.so.0
#4 0x002d21ec in g_array_new () from /usr/lib/libglib-2.0.so.0
#5 0x080bb32f in args_register (options=0x80f4360) at args.c:29
#6 0x080bf2d1 in core_init_paths (argc=1, argv=0xbff59974) at core.c:193
#7 0x0806ae5d in main (argc=1, argv=0xbff59974) at irssi.c:341
</pre>

Using latest irssi from RPMforge with gc 7.0. If I downgrade to gc 6.8 all works again.
Faux (Faux)
Tuesday, 08 January 2008, 02:00 GMT
Similar results under ubuntu x32 and debian amd64, interestingly in a completely different place to the people above, with 0.8.12:

faux@newton:~/irssi-812$ #./configure --with-gc --enable-debug=full --with-debug
faux@newton:~/irssi-812$ #make
faux@newton:~/irssi-812$ #sudo make install

faux@newton:~/irssi-812$ which irssi
/usr/local/bin/irssi

faux@newton:~/irssi-812$ $(which irssi)
Segmentation fault (core dumped)
faux@newton:~/irssi-812$ $(which irssi) --version
irssi 0.8.12 (20071008 1749)

faux@newton:~/irssi-812$ gdb $(which irssi)
GNU gdb 6.6-debian
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i486-linux-gnu"...
Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1".
(gdb) r
Starting program: /usr/local/bin/irssi
[Thread debugging using libthread_db enabled]
[New Thread -1214146352 (LWP 29133)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1214146352 (LWP 29133)]
0xb7bcfb2d in GC_free () from /usr/lib/libgc.so.1
(gdb) bt
#0 0xb7bcfb2d in GC_free () from /usr/lib/libgc.so.1
#1 0xb7daa131 in g_free () from /usr/lib/libglib-2.0.so.0
#2 0xb7d95ed2 in ?? () from /usr/lib/libglib-2.0.so.0
#3 0x081737f8 in ?? ()
#4 0x0000001c in ?? ()
#5 0xbfc933c8 in ?? ()
#6 0xb7d96537 in g_hash_table_lookup () from /usr/lib/libglib-2.0.so.0
#7 0x080ddcd0 in signal_add_full_id (module=0x80f37d5 "fe-common/irc/dcc", priority=557, signal_id=508, func=0x8080570 <sig_message_dcc_own>, user_data=0x0) at signals.c:107
#8 0x08080692 in fe_dcc_chat_messages_init () at fe-dcc-chat-messages.c:142
#9 0x0807fdf0 in fe_dcc_chat_init () at fe-dcc-chat.c:350
#10 0x0807e9db in fe_irc_dcc_init () at fe-dcc.c:159
#11 0x08073c3b in fe_irc_modules_init () at irc-modules.c:4
#12 0x08072115 in main (argc=356352, argv=0x0) at irssi.c:154
(gdb) q
The program is running. Exit anyway? (y or n) y

faux@newton:~/irssi-812$ apt-cache show libglib2.0-dev libgc-dev build-essential gcc libncurses5-dev libc6-dev autotools-dev openssl libperl-dev | egrep '^(Package|Version)'
Package: libglib2.0-dev
Version: 2.12.11-0ubuntu1
Package: libgc-dev
Version: 1:6.8-1ubuntu2
Package: build-essential
Version: 11.3
Package: gcc
Version: 4:4.1.2-1ubuntu1
Package: libncurses5-dev
Version: 5.5-5ubuntu2
Package: libc6-dev
Version: 2.5-0ubuntu14
Package: autotools-dev
Version: 20060920.1
Package: openssl
Version: 0.9.8c-4ubuntu0.2
Package: openssl
Version: 0.9.8c-4build1
Package: libperl-dev
Version: 5.8.8-7ubuntu0.1
Package: libperl-dev
Version: 5.8.8-7build1

faux@newton:~/irssi-812$ uname -a
Linux newton 2.6.20-16-386 #2 Sun Sep 23 19:47:10 UTC 2007 i686 GNU/Linux
Emanuele Giaquinta (ayin)
Friday, 14 March 2008, 20:29 GMT
It is because of the default glib memory allocator. Try with G_SLICE=always-malloc irssi
David (phyber)
Wednesday, 04 June 2008, 11:01 GMT
Starting irssi with 'G_SLICE=always-malloc irssi' does indeed stop it from Segfaulting and/or dumping core (only tested by starting irssi, didn't attempt anything else).
Is there a way to have irssi automatically set that if it's compiled with GC? If not, it should probably be commented on in the output of ./configure when a user compiles --with-gc.

Loading...