comparison lisp/progmodes/gdb-ui.el @ 67164:c3990f178905

(gdb-stopped): Detect process when attaching. (gdb-pre-prompt): Make sure gdb-error is reset.
author Nick Roberts <nickrob@snap.net.nz>
date Sun, 27 Nov 2005 22:16:02 +0000
parents bd64098ea241
children f8729e3300dc
comparison
equal deleted inserted replaced
67163:3653ab7f7e3c 67164:c3990f178905
1011 1011
1012 (defun gdb-pre-prompt (ignored) 1012 (defun gdb-pre-prompt (ignored)
1013 "An annotation handler for `pre-prompt'. 1013 "An annotation handler for `pre-prompt'.
1014 This terminates the collection of output from a previous command if that 1014 This terminates the collection of output from a previous command if that
1015 happens to be in effect." 1015 happens to be in effect."
1016 (setq gdb-error nil)
1016 (let ((sink gdb-output-sink)) 1017 (let ((sink gdb-output-sink))
1017 (cond 1018 (cond
1018 ((eq sink 'user) t) 1019 ((eq sink 'user) t)
1019 ((eq sink 'emacs) 1020 ((eq sink 'emacs)
1020 (setq gdb-output-sink 'post-emacs)) 1021 (setq gdb-output-sink 'post-emacs))
1103 (defun gdb-stopped (ignored) 1104 (defun gdb-stopped (ignored)
1104 "An annotation handler for `stopped'. 1105 "An annotation handler for `stopped'.
1105 It is just like `gdb-stopping', except that if we already set the output 1106 It is just like `gdb-stopping', except that if we already set the output
1106 sink to `user' in `gdb-stopping', that is fine." 1107 sink to `user' in `gdb-stopping', that is fine."
1107 (setq gud-running nil) 1108 (setq gud-running nil)
1109 (setq gdb-active-process t)
1108 (let ((sink gdb-output-sink)) 1110 (let ((sink gdb-output-sink))
1109 (cond 1111 (cond
1110 ((eq sink 'inferior) 1112 ((eq sink 'inferior)
1111 (setq gdb-output-sink 'user)) 1113 (setq gdb-output-sink 'user))
1112 ((eq sink 'user) t) 1114 ((eq sink 'user) t)