Subject: bug#5060 closed by [email-masked] (Nick Roberts) (Re: bug#5060: More debugging information)

From: [email-masked] (Emacs bug Tracking System)
Date: Mon, 14 Dec 2009 09:55:09 +0000

This is an automatic notification regarding your bug report
which was filed against the emacs package:

#5060: 23.1.50; GDB MI error (wrong-type-argument stringp nil)

It has been closed by [email-masked] (Nick Roberts).

Their explanation is attached below along with your original report.
If this explanation is unsatisfactory and you have not received a
better one in a separate message then please contact [email-masked] (Nick Roberts) by
replying to this email.

-- 
5060: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=5060
Emacs Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#5060: More debugging information
From: [email-masked] (Nick Roberts)
To: Michael Welsh Duggan <[email-masked]>
Cc: [email-masked]
Date: Mon, 14 Dec 2009 22:48:34 +1300

 > > That sounds right.  Using gdb-frame-handler to get the current line is
 > > a bit of a hack because gdb doesn't always print the location when it
 > > stops.  This code doesn't look quite right.  Does the patch below
 > > work?
 > 
 > It does work.  ...

I've committed this change now and closed the report.

-- 
Nick                                           http://users.snap.net.nz/~nickrob

Subject: 23.1.50; GDB MI error (wrong-type-argument stringp nil)
From: Michael Welsh Duggan <[email-masked]>
To: [email-masked]
Date: Fri, 27 Nov 2009 12:18:36 -0500

Please describe exactly what actions triggered the bug
and the precise symptoms of the bug:

I am running gdb over lilypond, which is a very large C++ program with
embedded guile.  At a certain point, if I type `n', I end up with a dead
debugging environment, and a signalled error (wrong-type-argument
stringp nil) which comes from gud-find-file (on nil) via
gud-display-frame.

I am including the Backtrace after toggling debug-on-error, and the
value of gdb-debug-log.  If there is anything more I can do to debug
this problem, please let me know.

Debugger entered--Lisp error: (wrong-type-argument stringp nil)
  string-match("//+" nil)
  gud-find-file(nil)
  gud-display-line(nil 29)
  gud-display-frame()
  gdb-frame-handler()
  gdb-done-or-error("frame={level=\"0\",addr=\"0xb79ef6c1\",func=\"__libc_siglongjmp\",file=\"longjmp.c\",line=\"29\"}" "20" done)
gdb-debug-log is a variable defined in `gdb-mi.el'.
Its value is shown below.

Documentation:
List of commands sent to and replies received from GDB.
Most recent commands are listed first.  This list stores only the last
`gdb-debug-log-max' values.  This variable is used to debug GDB-MI.

Value: 
 (send-item "21-break-list"
            (lambda
              (&rest args)
              (with-current-buffer #<buffer *breakpoints of lilypond*>
                                   (apply 'gdb-breakpoints-list-handler args))))
 (send-item "20-stack-info-frame --thread 1" gdb-frame-handler)
 (recv . "=library-loaded,id=\"/usr/lib/libguile-srfi-srfi-1-v-3.so.3\",target-name=\"/usr/lib/libguile-srfi-srfi-1-v-3.so.3\",host-name=\"/usr/lib/libguile-srfi-srfi-1-v-3.so.3\",symbols-loaded=\"0\"\n")
 (send-item "19-thread-info --thread 1"
            (lambda
              (&rest args)
              (with-current-buffer #<buffer *threads of lilypond*>
                                   (apply 'gdb-thread-list-handler args))))
 (recv . "^running\n*running,thread-id=\"1\"\n(gdb) \n")
 (mi-send .
          #("n\n" 0 1
            (fontified t)))
 (send-item "18-break-list"
            (lambda
              (&rest args)
              (with-current-buffer #<buffer *breakpoints of lilypond*>
                                   (apply 'gdb-breakpoints-list-handler args))))
 (send-item "17-stack-info-frame --thread 1" gdb-frame-handler)
 (send-item "16-data-list-register-names --thread 1" gdb-register-names-handler)
 (recv . "(gdb) \n")
 (recv . "=library-loaded,id=\"/lib/ld-linux.so.2\",target-name=\"/lib/ld-linux.so.2\",host-name=\"/lib/ld-linux.so.2\",symbols-loaded=\"0\"\n")
 (send-item "15-thread-info"
            (lambda
              (&rest args)
              (with-current-buffer #<buffer *threads of lilypond*>
                                   (apply 'gdb-thread-list-handler args))))
 (recv . "=thread-group-created,id=\"18019\"\n=thread-created,id=\"1\",group-id=\"18019\"\n^running\n*running,thread-id=\"all\"\n")
 (recv . "~\"Starting program: /usr/local/bin/lilypond ~/lily/test31.ly\\n\"\n")
 (mi-send .
          #("run ~/lily/test31.ly\n" 0 20
            (fontified t)))
 (recv . "12^error,msg=\"No registers.\"\n(gdb) \n13^done,threads=[]\n(gdb) \n")
 (send-item "14-break-list"
            (lambda
              (&rest args)
              (with-current-buffer #<buffer *breakpoints of lilypond*>
                                   (apply 'gdb-breakpoints-list-handler args))))
 (send-item "13-thread-info"
            (lambda
              (&rest args)
              (with-current-buffer #<buffer *threads of lilypond*>
                                   (apply 'gdb-thread-list-handler args))))
 (send-item "12-stack-info-frame" gdb-frame-handler)
 (recv . "~\"Breakpoint 1 at 0x812d54e: file guile-init.cc, line 63.\\n\"\n^done\n(gdb) \n")
 (mi-send .
          #("b ly_c_init_guile\n" 0 17
            (fontified t)))
 (send-item "11-enable-pretty-printing" ignore)
 (send-item "10-gdb-set target-async 1" ignore)
 (recv . "~\"done.\\n\"\n(gdb) \n1^done\n(gdb) \n2^done\n(gdb) \n3^done\n(gdb) \n")
 (recv . "~\"Reading symbols from /usr/local/bin/lilypond...\"\n")
 (recv . "~\"GNU gdb (GDB) 7.0-debian\\n\"\n~\"Copyright (C) 2009 Free Software Foundation, Inc.\\n\"\n~\"License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\\n\"\n~\"This is free software: you are free to change and redistribute it.\\n\"\n~\"There is NO WARRANTY, to the extent permitted by law.  Type \\\"show copying\\\"\\n\"\n~\"and \\\"show warranty\\\" for details.\\n\"\n~\"This GDB was configured as \\\"i486-linux-gnu\\\".\\n\"\n~\"For bug reporting instructions, please see:\\n\"\n~\"<http://www.gnu.org/software/gdb/bugs/>...\\n\"\n")
 (send-item "9-break-list"
            (lambda
              (&rest args)
              (with-current-buffer #<buffer *breakpoints of lilypond*>
                                   (apply 'gdb-breakpoints-list-handler args))))
 (send-item "8-thread-info"
            (lambda
              (&rest args)
              (with-current-buffer #<buffer *threads of lilypond*>
                                   (apply 'gdb-thread-list-handler args))))
 (send-item "7-stack-info-frame" gdb-frame-handler)
 (send-item "6-gdb-show prompt" gdb-get-prompt)
 (send-item "5-file-list-exec-source-file" gdb-get-source-file)
 (send-item "4-file-list-exec-source-files" gdb-get-source-file-list)
 (send-item "3-gdb-set non-stop 1" gdb-non-stop-handler)
 (send-item "2-gdb-set height 0" ignore)
 (send-item "1-inferior-tty-set /dev/pts/13" ignore))

[back]

In GNU Emacs 23.1.50.1 (i686-pc-linux-gnu, GTK+ Version 2.18.3)
 of 2009-10-30 on maru
Windowing system distributor `The X.Org Foundation', version 11.0.10605000
configured using `configure  '--without-toolkit-scroll-bars''

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: C
  value of $XMODIFIERS: nil
  locale-coding-system: nil
  default enable-multibyte-characters: t

Major mode: Help

Minor modes in effect:
  gpm-mouse-mode: t
  display-time-mode: t
  diff-auto-refine-mode: t
  shell-dirtrack-mode: t
  tooltip-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  global-auto-composition-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  view-mode: t

Recent input:
<backspace> 1 . l y <return> C-c C-n <switch-frame> 
C-p C-p C-p C-p C-p C-p C-h v <return> C-x o C-v C-v 
C-v C-v C-v C-x 1 <escape> > M-v M-v M-v M-v M-v M-v 
<escape> < <help-echo> <switch-frame> C-x k y e s <return> 
M-x g d b <return> M-p <return> <switch-frame> C-f 
C-f C-f C-h v <return> <escape> > <escape> < C-h v 
<return> C-v M-v C-n C-n C-n C-n C-n C-n C-n C-n C-n 
C-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f 
C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f 
C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f 
C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f 
C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f 
C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f 
C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f 
C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f 
C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f C-M-f 
C-M-f C-M-f C-M-f C-M-f C-M-f <escape> < C-n C-n C-n 
C-n C-n C-n C-n C-n C-n C-f C-M-f C-M-b C-M-f C-M-f 
C-M-b C-M-b <escape> > <switch-frame> M-x s e t - d 
e e <backspace> b <tab> <backspace> <backspace> <backspace> 
<backspace> - v a <tab> C-g C-g M-x t o g g l e - d 
e b <tab> e <tab> <return> b SPC l y _ c _ i n i t 
_ g u i l e <return> r u n SPC ~ / p r o j e <switch-frame> 
<escape> < C-h v <return> <help-echo> <switch-frame> 
<M-backspace> l i l y / t e s t 3 1 . l y <return> 
<help-echo> <switch-frame> C-h v <return> C-v M-v <help-echo> 
<help-echo> <help-echo> <switch-frame> n <return> <help-echo> 
<switch-frame> M-x r e p o r t - e m <tab> <return

Recent messages:
Reading active file from localimap via nnimap...
nnimap: Checking mailboxes...done
Reading active file from archive via nnfolder...done
Checking new news...done
Mark set [2 times]
Don't touch it!  It's the History Eraser Button, you fool! [2 times]
Debug on Error enabled globally
Mark set
Switched to thread 1
Entering debugger...

Load-path shadows:
/usr/local/share/emacs/site-lisp/lilypond-words hides /usr/share/emacs/site-lisp/lilypond-words
/usr/local/share/emacs/site-lisp/lilypond-indent hides /usr/share/emacs/site-lisp/lilypond-indent
/usr/local/share/emacs/site-lisp/lilypond-mode hides /usr/share/emacs/site-lisp/lilypond-mode
/home/md5i/src/elisp/psvn hides /usr/share/emacs/site-lisp/psvn
/usr/local/share/emacs/site-lisp/lilypond-song hides /usr/share/emacs/site-lisp/lilypond-song
/usr/local/share/emacs/site-lisp/lilypond-what-beat hides /usr/share/emacs/site-lisp/lilypond-what-beat
/usr/local/share/emacs/site-lisp/lilypond-font-lock hides /usr/share/emacs/site-lisp/lilypond-font-lock
/usr/local/share/emacs/site-lisp/lilypond-init hides /usr/share/emacs/site-lisp/lilypond-init

Features:
(emacsbug gdb-mi bindat json gud lilypond-mode texinfo cl-specs edebug
debug thai-util thai-word sh-script executable python-21 python sym-comp
calc-menu calc calc-loaddefs calc-macs etags rect cus-edit cus-start
cus-load image-mode tabify man find-func generic semantic/find
srecode/srt-mode semantic/analyze semantic/sort semantic/scope
semantic/analyze/fcn semantic/db semantic/format ezimage
srecode/template srecode/srt-wy semantic/wisent semantic/wisent/wisent
semantic/ctxt srecode/ctxt semantic/tag-ls srecode/compile srecode/table
srecode srecode/loaddefs eieio-base semantic/util-modes semantic/util
semantic semantic/tag semantic/lex semantic/fw semantic/loaddefs eieio
mode-local cedet vc-git shadow grep arc-mode archive-mode nxml-uchnm
rng-xsd xsd-regexp rng-cmpct rng-nxml rng-valid rng-loc rng-uri
rng-parse nxml-parse rng-match rng-dt rng-util rng-pttrn nxml-ns
nxml-mode nxml-outln nxml-rap nxml-util nxml-glyph nxml-enc xmltok
gnus-dup conf-mode newcomment noutline outline flow-fill ps-print ps-def
lpr picture cc-mode cc-fonts cc-menus cc-cmds cc-styles cc-align
cc-engine cc-vars cc-defs warnings jka-compr info dabbrev vc vc-rcs
bbdb-hooks browse-url multi-isearch help-mode view mule-util
vc-dispatcher vc-svn gnus-cite ansi-color gnus-async gnus-bcklg
parse-time sort byte-opt bytecomp byte-compile gnus-ml disp-table
gnus-topic nnfolder utf-7 utf7 rfc2104 nnimap nndraft nnmh bbdb-gnus
bbdb-snarf mail-extr bbdb-com nnml gnus-agent gnus-srvr gnus-score
score-mode nnvirtual gnus-msg gnus-art mm-uu mml2015 mm-view smime dig
gnus-cache edmacro kmacro gnus-demon nntp nnir gnus-sum gnus-group
gnus-undo nnmail mail-source nnoo gnus-start gnus-spec gnus-int
gnus-range gnus-win gnus gnus-ems t-mouse server uptimes pp uniquify
descr-text tramp-imap epa epg epg-config imap-hash imap assoc tramp-gw
tramp-fish tramp-smb tramp-cache tramp-ftp tramp-cmds tramp auth-source
format-spec tramp-compat trampver time scroll-in-place sgml-mode psvn
log-edit pcvs-util add-log diff-mode easy-mmode inf-caml camldebug
thingatpt derived shell caml-types caml-emacs caml-font caml advice
help-fns advice-preload compile imenu message sendmail ecomplete rfc822
mml easymenu mml-sec password-cache mm-decode mm-bodies mm-encode
mailcap mail-parse rfc2231 rfc2047 rfc2045 qp ietf-drums mailabbrev
nnheader gnus-util netrc time-date mm-util mail-prsvr gmm-utils wid-edit
mailheader canlock sha1 hex-util hashcash mail-utils generic-x debian-el
debian-el-loaddefs dired-x dired-aux dired bbdb-autoloads bbdb timezone
ange-ftp regexp-opt comint ring cl cl-19 tooltip ediff-hook vc-hooks
lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image fringe
lisp-mode register page menu-bar rfn-eshadow timer select scroll-bar
mldrag mouse jit-lock font-lock syntax facemenu font-core frame cham
georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese hebrew greek romanian slovak czech european ethiopic
indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple
abbrev loaddefs button minibuffer faces cus-face text-properties overlay
md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote make-network-process dbusbind gtk
x-toolkit x multi-tty emacs)

-- 
Michael Welsh Duggan
([email-masked])