From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <707a28fcbf71660486c09890402566ef@sorosj.hd.free.fr> Date: Sun, 14 Oct 2007 09:26:30 +0200 From: johnny@sorosj.hd.free.fr To: 9fans@cse.psu.edu Subject: Re: [9fans] drawterm segfault In-Reply-To: <9bf85e4c5603aa534c9705d22bc2a8ad@quanstro.net> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Topicbox-Message-UUID: cfe5c9c8-ead2-11e9-9d60-3106f5b1d025 you were right, that was just one thread. Now I used thread apply all bt command to get the backtrace. Here is what I got: ===== Begin gdb output ===== $ gdb 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". (gdb) attach 13176 Attaching to process 13176 Reading symbols from /usr/bin/drawterm...(no debugging symbols found)...done. Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1". Reading symbols from /usr/lib/libX11.so.6...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libX11.so.6 Reading symbols from /lib/tls/i686/cmov/libpthread.so.0...(no debugging symbols found)...done. [Thread debugging using libthread_db enabled] [New Thread -1210783072 (LWP 13176)] [New Thread -1250116720 (LWP 13183)] [New Thread -1241724016 (LWP 13182)] [New Thread -1233331312 (LWP 13179)] [New Thread -1224938608 (LWP 13178)] [New Thread -1216283760 (LWP 13177)] Loaded symbols for /lib/tls/i686/cmov/libpthread.so.0 Reading symbols from /lib/tls/i686/cmov/libc.so.6...(no debugging symbols found)...done. Loaded symbols for /lib/tls/i686/cmov/libc.so.6 Reading symbols from /usr/lib/libXau.so.6... (no debugging symbols found)...done. Loaded symbols for /usr/lib/libXau.so.6 Reading symbols from /usr/lib/libXdmcp.so.6...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libXdmcp.so.6 Reading symbols from /lib/tls/i686/cmov/libdl.so.2...(no debugging symbols found)...done. Loaded symbols for /lib/tls/i686/cmov/libdl.so.2 Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done. Loaded symbols for /lib/ld-linux.so.2 Reading symbols from /lib/tls/i686/cmov/libnss_compat.so.2... (no debugging symbols found)...done. Loaded symbols for /lib/tls/i686/cmov/libnss_compat.so.2 Reading symbols from /lib/tls/i686/cmov/libnsl.so.1...(no debugging symbols found)...done. Loaded symbols for /lib/tls/i686/cmov/libnsl.so.1 Reading symbols from /lib/tls/i686/cmov/libnss_nis.so.2...(no debugging symbols found)...done. Loaded symbols for /lib/tls/i686/cmov/libnss_nis.so.2 Reading symbols from /lib/tls/i686/cmov/libnss_files.so.2...(no debugging symbols found)...done. Loaded symbols for /lib/tls/i686/cmov/libnss_files.so.2 Reading symbols from /usr/lib/libXcursor.so.1... (no debugging symbols found)...done. Loaded symbols for /usr/lib/libXcursor.so.1 Reading symbols from /usr/lib/libXrender.so.1...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libXrender.so.1 Reading symbols from /usr/lib/libXfixes.so.3...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libXfixes.so.3 (no debugging symbols found) 0xffffe410 in __kernel_vsyscall () (gdb) continue Continuing. Program received signal SIGSEGV, Segmentation fault. [Switching to Thread -1224938608 (LWP 13178)] 0x08086210 in ?? () (gdb) thread apply all bt Thread 6 (Thread -1216283760 (LWP 13177)): #0 0xffffe410 in __kernel_vsyscall () #1 0xb7e24647 in poll () from /lib/tls/i686/cmov/libc.so.6 #2 0xb7efb839 in ?? () from /usr/lib/libX11.so.6 #3 0x080e1178 in ?? () #4 0x00000001 in ?? () #5 0xffffffff in ?? () #6 0xb7fabb2c in ?? () from /usr/lib/libX11.so.6 #7 0x080e0b60 in ?? () #8 0xb7fabb2c in ?? () from /usr/lib/libX11.so.6 #9 0x080e0b60 in ?? () #10 0x00000000 in ?? () Thread 5 (Thread -1224938608 (LWP 13178)): #0 0x08086210 in ?? () #1 0x00000000 in ?? () Thread 4 (Thread -1233331312 (LWP 13179)): #0 0xffffe410 in __kernel_vsyscall () #1 0xb7eaf676 in pthread_cond_wait@@GLIBC_2.3.2 () from /lib/tls/i686/cmov/libpthread.so.0 #2 0x0805d8fc in ?? () #3 0x08107420 in ?? () #4 0x08107408 in ?? () #5 0xb67ccd48 in ?? () #6 0x081065dc in ?? () #7 0x00000000 in ?? () Thread 3 (Thread -1241724016 (LWP 13182)): #0 0xffffe410 in __kernel_vsyscall () #1 0xb7eaf676 in pthread_cond_wait@@GLIBC_2.3.2 () from /lib/tls/i686/cmov/libpthread.so.0 #2 0x0805d8fc in ?? () #3 0x0810e8f0 in ?? () #4 0x0810e8d8 in ?? () #5 0xb5fcbce8 in ?? () #6 0x080d2ec4 in ?? () #7 0x080d2e80 in ?? () ---Type to continue, or q to quit--- #8 0x0805b710 in ?? () #9 0xb5fcbd18 in ?? () #10 0x08058f10 in ?? () #11 0x080d2ec4 in ?? () #12 0x00002e60 in ?? () #13 0xb5fcbd08 in ?? () #14 0x0808de51 in ?? () #15 0x080d2e80 in ?? () #16 0x00000014 in ?? () #17 0x00000000 in ?? () Thread 2 (Thread -1250116720 (LWP 13183)): #0 0xffffe410 in __kernel_vsyscall () #1 0xb7eaf676 in pthread_cond_wait@@GLIBC_2.3.2 () from /lib/tls/i686/cmov/libpthread.so.0 #2 0x0805d8fc in ?? () #3 0x08111f88 in ?? () #4 0x08111f70 in ?? () #5 0xb57cae28 in ?? () #6 0x080bcf58 in ?? () #7 0x00000000 in ?? () Thread 1 (Thread -1210783072 (LWP 13176)): #0 0xffffe410 in __kernel_vsyscall () #1 0xb7eb2518 in recv () from /lib/tls/i686/cmov/libpthread.so.0 #2 0x08054666 in ?? () #3 0x00000007 in ?? () #4 0x08116720 in ?? () #5 0x00010000 in ?? () #6 0x00000000 in ?? () #0 0x08086210 in ?? () (gdb) ===== end gdb output ====== I would like to be able to say something about this core file everyone seems to deem more reliable in debugging than gdb, but I don't really know how I can obtain it. I'm running ubuntu 7.10 (gutsy). I won't be able to debug the sunos version for a few days yet, as we only use those machines for classes, but it seemed it was the same problem: drawterm in, then start acme, navigate to wc.c (this is actually not the only file that induces this behaviour), and drawterm segfaults. Thanks for the help!