On Mon, Nov 19, 2007 at 01:57:04AM +0100, Jan Christoph Nordholz wrote: > Now I have at least a faint idea what I should be looking for in the source > code... maybe you could speed it up by setting a watchpoint? > > 1. start rxvt-xterm inside gdb > 2. fire up mutt, open the first mail > 3. CTRL+C... > > ] (gdb) p screen.text[TermWin.saveLines] > // check: should be the top line of your window > ] (gdb) watch (void *)screen.text[TermWin.saveLines] > ] Hardware watchpoint 1: (void *)screen.text[TermWin.saveLines] > ] (gdb) c > ] Continuing. > > 4. Try to reproduce the crash. > > Now it should not get to the segfault, but interrupt somewhere in between > (exactly at the position where those buffer pointers are altered). > I guess I don't need a core file then - a 'bt full' should provide all > that's necessary to guide my search. ;)
Okay... (gdb) r Starting program: /home/joy/QA/rxvt/rxvt-2.6.4/src/rxvt-xterm Program received signal SIGTSTP, Stopped (user). 0x00002b0ce3dd9a75 in select () from /lib/libc.so.6 (gdb) p screen.text[TermWin.saveLines] $1 = ( text_t *) 0x54dfa0 "i:Exit -:PrevPg <Space>:NextPg v:View Attachm. d:Del r:Reply j:Next ?:Help " (gdb) watch (void *)screen.text[TermWin.saveLines] Hardware watchpoint 1: (void *) screen.text[TermWin.saveLines] (gdb) c Continuing. Program received signal SIGTSTP, Stopped (user). 0x00002b0ce3dd9a75 in select () from /lib/libc.so.6 (gdb) c Continuing. Hardware watchpoint 1: (void *) screen.text[TermWin.saveLines] Old value = (void *) 0x54dfa0 New value = (void *) 0x543a10 scroll_text (row1=0, row2=518, count=10, spec=0) at screen.c:803 803 screen.tlen[j] = screen.tlen[j + count]; (gdb) c Continuing. [here it's actually just stuck again... so I press Ctrl+Z] Program received signal SIGTSTP, Stopped (user). 0x00000000004102e2 in scr_add_lines ( str=0x51cdcc "***** Nagios *****\r\n\nNotification Type: PROBLEM\r\nHost: nekkar.CARNet.hr\r\nState: DOWN\r\nAddress: 161.53.160.239\r\nInfo:\r\n\nCRITICAL - Host Unreachable (161.53.160.239)\r\n\nDate/Time: Sun Jul 22 15:43:45 CE"..., nlines=-4, len=207) at screen.c:1012 1012 stp[screen.cur.col] = c; (gdb) bt full #0 0x00000000004102e2 in scr_add_lines ( str=0x51cdcc "***** Nagios *****\r\n\nNotification Type: PROBLEM\r\nHost: nekkar.CARNet.hr\r\nState: DOWN\r\nAddress: 161.53.160.239\r\nInfo:\r\n\nCRITICAL - Host Unreachable (161.53.160.239)\r\n\nDate/Time: Sun Jul 22 15:43:45 CE"..., nlines=-4, len=207) at screen.c:1012 c = 42 '*' i = 1 j = 0 row = 509 last_col = 80 checksel = 0 clearsel = 0 stp = (text_t *) 0x0 srp = (u_int16_t *) 0x0 #1 0x0000000000408d47 in main_loop () at command.c:3307 nlines = 10 ch = 27 '\033' str = ( unsigned char *) 0x51cdcc "***** Nagios *****\r\n\nNotification Type: PROBLEM\r\nHost: nekkar.CARNet.hr\r\nState: DOWN\r\nAddress: 161.53.160.239\r\nInfo:\r\n\nCRITICAL - Host Unreachable (161.53.160.239)\r\n\nDate/Time: Sun Jul 22 15:43:45 CE"... #2 0x000000000040cd40 in main (argc=1, argv=0x7fffc70b26d8) at main.c:1434 ---Type <return> to continue, or q <return> to quit--- cmd_argv = (const char **) 0x0 (gdb) -- 2. That which causes joy or happiness. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]