emacs-devel
[Top][All Lists]
Advanced

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

Re: other weird gdb-mi problems


From: Nick Roberts
Subject: Re: other weird gdb-mi problems
Date: Thu, 27 Aug 2009 16:52:58 +1200

 > p.s. What about emacs showing the wrong source file?

Actually, I take back what I said earlier.  Previously, "-stack-info-frame"
was actually used to query for the current frame but I see now that after
Dmitry's changes it now gets sent as, e.g.,

        "-stack-info-frame --thread 1 -frame --0"

which resets the frame.  The change below seems to fix this for the problem
you reported with "up" and "down" by just specifying the thread,

        "-stack-info-frame --thread 1"

but this might breaks things in a multi-threaded situation where Emacs might
want send a GDB command that operates on a different frame to the selected
one.

Dmitry, what do you think?

-- 
Nick                                           http://www.inet.net.nz/~nickrob


*** gdb-mi.el.~1.36.~   2009-08-25 09:58:16.000000000 +1200
--- gdb-mi.el   2009-08-27 16:35:02.000000000 +1200
*************** then no --frame option is added."
*** 1605,1614 ****
    ;; gdb-frame-number may be nil while gdb-thread-number is non-nil
    ;; (when current thread is running)
    (if gdb-thread-number
!       (concat command " --thread " gdb-thread-number
!               (if (not (or noframe (not gdb-frame-number)))
!                   (concat " --frame " gdb-frame-number) "")
!               " ")
      command))
  
  (defun gdb-current-context-buffer-name (name)
--- 1605,1611 ----
    ;; gdb-frame-number may be nil while gdb-thread-number is non-nil
    ;; (when current thread is running)
    (if gdb-thread-number
!       (concat command " --thread " gdb-thread-number)
      command))
  
  (defun gdb-current-context-buffer-name (name)




reply via email to

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