aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2009-11-27 19:31:57 +0000
committerStefan Monnier2009-11-27 19:31:57 +0000
commitc5269f1cd5bb589342127015860890e03e8bdf96 (patch)
tree9a0570e3d2cde2c4c735b77757b83111a4bf2c34
parentece2d4ed181649ebdac464f8149527a9ce75d4ad (diff)
downloademacs-c5269f1cd5bb589342127015860890e03e8bdf96.tar.gz
emacs-c5269f1cd5bb589342127015860890e03e8bdf96.zip
(gud-basic-call): Don't only save the buffer but the excursion as well.
-rw-r--r--lisp/ChangeLog8
-rw-r--r--lisp/progmodes/gud.el25
2 files changed, 20 insertions, 13 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 6e719cfe520..579ae1e7af1 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12009-11-27 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * progmodes/gud.el (gud-basic-call): Don't only save the buffer but
4 the excursion as well.
5
12009-11-27 Michael Albinus <michael.albinus@gmx.de> 62009-11-27 Michael Albinus <michael.albinus@gmx.de>
2 7
3 * eshell/em-unix.el (eshell/su, eshell/sudo): New defuns, 8 * eshell/em-unix.el (eshell/su, eshell/sudo): New defuns,
@@ -17,7 +22,8 @@
17 * man.el (Man-completion-table): Trim a terminating "(". 22 * man.el (Man-completion-table): Trim a terminating "(".
18 Remove the space between name page a section. 23 Remove the space between name page a section.
19 Add the command's description on the `help-echo' property. 24 Add the command's description on the `help-echo' property.
20 Remove `process-connection-type' binding since it's unused by call-process. 25 Remove `process-connection-type' binding since it's unused by
26 call-process.
21 Provide completion for the "<section> <name>" format as well. 27 Provide completion for the "<section> <name>" format as well.
22 (Man-default-man-entry): Remove spurious var shadowing the argument. 28 (Man-default-man-entry): Remove spurious var shadowing the argument.
23 29
diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el
index cbb0f46bdca..9b8947a616a 100644
--- a/lisp/progmodes/gud.el
+++ b/lisp/progmodes/gud.el
@@ -2832,18 +2832,19 @@ Obeying it means displaying in another window the specified file and line."
2832 (or proc (error "Current buffer has no process")) 2832 (or proc (error "Current buffer has no process"))
2833 ;; Arrange for the current prompt to get deleted. 2833 ;; Arrange for the current prompt to get deleted.
2834 (with-current-buffer gud-comint-buffer 2834 (with-current-buffer gud-comint-buffer
2835 (save-restriction 2835 (save-excursion
2836 (widen) 2836 (save-restriction
2837 (if (marker-position gud-delete-prompt-marker) 2837 (widen)
2838 ;; We get here when printing an expression. 2838 (if (marker-position gud-delete-prompt-marker)
2839 (goto-char gud-delete-prompt-marker) 2839 ;; We get here when printing an expression.
2840 (goto-char (process-mark proc)) 2840 (goto-char gud-delete-prompt-marker)
2841 (forward-line 0)) 2841 (goto-char (process-mark proc))
2842 (if (looking-at comint-prompt-regexp) 2842 (forward-line 0))
2843 (set-marker gud-delete-prompt-marker (point))) 2843 (if (looking-at comint-prompt-regexp)
2844 (if (eq gud-minor-mode 'gdbmi) 2844 (set-marker gud-delete-prompt-marker (point)))
2845 (apply comint-input-sender (list proc command)) 2845 (if (eq gud-minor-mode 'gdbmi)
2846 (process-send-string proc (concat command "\n"))))))) 2846 (apply comint-input-sender (list proc command))
2847 (process-send-string proc (concat command "\n"))))))))
2847 2848
2848(defun gud-refresh (&optional arg) 2849(defun gud-refresh (&optional arg)
2849 "Fix up a possibly garbled display, and redraw the arrow." 2850 "Fix up a possibly garbled display, and redraw the arrow."