aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/gud.el13
1 files changed, 8 insertions, 5 deletions
diff --git a/lisp/gud.el b/lisp/gud.el
index bf728b6c6a1..1734a95636e 100644
--- a/lisp/gud.el
+++ b/lisp/gud.el
@@ -934,7 +934,8 @@ comint mode, which see."
934 934
935(defun gud-filter (proc string) 935(defun gud-filter (proc string)
936 ;; Here's where the actual buffer insertion is done 936 ;; Here's where the actual buffer insertion is done
937 (let ((inhibit-quit t)) 937 (let ((inhibit-quit t)
938 output)
938 (save-excursion 939 (save-excursion
939 (set-buffer (process-buffer proc)) 940 (set-buffer (process-buffer proc))
940 ;; If we have been so requested, delete the debugger prompt. 941 ;; If we have been so requested, delete the debugger prompt.
@@ -942,9 +943,8 @@ comint mode, which see."
942 (progn 943 (progn
943 (delete-region (process-mark proc) gud-delete-prompt-marker) 944 (delete-region (process-mark proc) gud-delete-prompt-marker)
944 (set-marker gud-delete-prompt-marker nil))) 945 (set-marker gud-delete-prompt-marker nil)))
945 ;; Let the comint filter do the actual insertion. 946 ;; Save the process output, checking for source file markers.
946 ;; That lets us inherit various comint features. 947 (setq output (gud-marker-filter string))
947 (comint-output-filter proc (gud-marker-filter string))
948 ;; Check for a filename-and-line number. 948 ;; Check for a filename-and-line number.
949 ;; Don't display the specified file 949 ;; Don't display the specified file
950 ;; unless (1) point is at or after the position where output appears 950 ;; unless (1) point is at or after the position where output appears
@@ -952,7 +952,10 @@ comint mode, which see."
952 (if (and gud-last-frame 952 (if (and gud-last-frame
953 (>= (point) (process-mark proc)) 953 (>= (point) (process-mark proc))
954 (get-buffer-window (current-buffer))) 954 (get-buffer-window (current-buffer)))
955 (gud-display-frame))))) 955 (gud-display-frame))
956 ;; Let the comint filter do the actual insertion.
957 ;; That lets us inherit various comint features.
958 (comint-output-filter proc output))))
956 959
957(defun gud-sentinel (proc msg) 960(defun gud-sentinel (proc msg)
958 (cond ((null (buffer-name (process-buffer proc))) 961 (cond ((null (buffer-name (process-buffer proc)))