From 78971dff706c88562bdd848d2aea623401dc7049 Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Thu, 10 Jan 2008 10:27:02 +0000 Subject: [PATCH] (gdb-dequeue-input): Make doubly sure session doesn't hang because gdb-pending-triggers is non-nil. (gdb-frame-handler): Use buffer-file-name instead of buffer-name in case of duplicate file names. --- lisp/progmodes/gdb-ui.el | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el index ef11668f022..d85bf23c7c5 100644 --- a/lisp/progmodes/gdb-ui.el +++ b/lisp/progmodes/gdb-ui.el @@ -1214,10 +1214,12 @@ This filter may simply queue input for a later time." (defun gdb-dequeue-input () (let ((queue gdb-input-queue)) - (and queue - (let ((last (car (last queue)))) - (unless (nbutlast queue) (setq gdb-input-queue '())) - last)))) + (if queue + (let ((last (car (last queue)))) + (unless (nbutlast queue) (setq gdb-input-queue '())) + last) + ;; This should be nil here anyway but set it just to make sure. + (setq gdb-pending-triggers nil)))) (defun gdb-send-item (item) (setq gdb-flush-pending-output nil) @@ -3442,7 +3444,8 @@ BUFFER nil or omitted means use the current buffer." (let ((buffer (marker-buffer gud-overlay-arrow-position)) (position (marker-position gud-overlay-arrow-position))) (when (and buffer - (string-equal (buffer-name buffer) + (string-equal (file-name-nondirectory + (buffer-file-name buffer)) (file-name-nondirectory (match-string 3)))) (with-current-buffer buffer (setq fringe-indicator-alist