bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#40210: 28.0.50; gdb-mi incorrectly handles EOF/C-d/gdb-io-eof when g


From: Eli Zaretskii
Subject: bug#40210: 28.0.50; gdb-mi incorrectly handles EOF/C-d/gdb-io-eof when gdb-many-windows is t. Additionally, variable documentation for gdb-many-windows is misleading.
Date: Tue, 24 Mar 2020 16:30:54 +0200

> From: Vladimir Nikishkin <lockywolf@gmail.com>
> Date: Tue, 24 Mar 2020 20:12:32 +0800
> 
> 1. emacs -q
> 2. M-: (require 'gdb-mi) RET
> 3. M-x set-variable RET gdb-many-windows RET t
> 4. gdb RET /usr/bin/cat RET
> 5. run
> 6. C-x b *input/output-of-cat* RET
> 7. C-d
> 
> Nothing happens, although EOF should be sent to the cat process.

Does the patch below give good results?

> Additionally, clicking on <menu> <signals> <EOF> kills gdb process
> rather than sending the EOF to the cat process.

That's expected, I think, since that sends EOF to GDB.

diff --git a/lisp/progmodes/gdb-mi.el b/lisp/progmodes/gdb-mi.el
index ea3b1b8..228e506 100644
--- a/lisp/progmodes/gdb-mi.el
+++ b/lisp/progmodes/gdb-mi.el
@@ -1747,7 +1747,7 @@ gdb-io-eof
   "Send end-of-file to the program being debugged."
   (interactive)
   (process-send-eof
-   (get-buffer-process gud-comint-buffer)))
+   (get-buffer-process (gdb-get-buffer-create 'gdb-inferior-io))))
 
 (defun gdb-clear-inferior-io ()
   (with-current-buffer (gdb-get-buffer-create 'gdb-inferior-io)





reply via email to

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