emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

gud.el bug + patch


From: Karl Chen
Subject: gud.el bug + patch
Date: Wed, 22 Mar 2006 20:54:52 -0800

I'm using Emacs HEAD 2006-03-15 and gdb 6.4.

When I run M-x gdb, I get
     
    Debugger entered--Lisp error: (wrong-type-argument stringp nil)
      get-buffer-window(nil)
      gdb-display-source-buffer(#<buffer breaker.cpp>)
      gud-display-line("/home/quarl/proj/debfsv/analyzer/smbase/breaker.cpp" 16)
      gud-display-frame()

I believe this is a bug in `gud-gdb-marker-filter', where
`gud-last-frame' gets set to
    ("source /path/file.cc" . 19)
I think this should be
    ("/path/file.cc" . 42).

`gdb --annotate=3' gives output such as:

^Z^Zsource /path/file.cc:19:512:beg:0x80f0031


This patch to `gud-gdb-marker-regexp' fixes the problem.


--- gud.el      16 Mar 2006 14:56:18 -0800      1.100
+++ gud.el      22 Mar 2006 20:48:03 -0800      
@@ -558,7 +558,7 @@
   ;; This used to use path-separator instead of ":";
   ;; however, we found that on both Windows 32 and MSDOS
   ;; a colon is correct here.
-  (concat "\032\032\\(.:?[^" ":" "\n]*\\)" ":"
+  (concat "\032\032\\(?:source \\)?\\(.:?[^" ":" "\n]*\\)" ":"
          "\\([0-9]*\\)" ":" ".*\n"))
 
 ;; There's no guarantee that Emacs will hand the filter the entire


-- 
Karl 2006-03-22 20:42




reply via email to

[Prev in Thread] Current Thread [Next in Thread]