GNU bug report logs - #65007
[PATCH] Allow displaying program IO in the GDB buffer.

Previous Next

Package: emacs;

Reported by: StrawberryTea <look <at> strawberrytea.xyz>

Date: Wed, 2 Aug 2023 08:07:01 UTC

Severity: wishlist

Tags: patch

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#65007: closed ([PATCH] Allow displaying program IO in the GDB
 buffer.)
Date: Sat, 16 Sep 2023 10:45:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Sat, 16 Sep 2023 13:44:37 +0300
with message-id <83fs3eiei2.fsf <at> gnu.org>
and subject line Re: bug#65007: [PATCH] Allow displaying program IO in the GDB buffer.
has caused the debbugs.gnu.org bug report #65007,
regarding [PATCH] Allow displaying program IO in the GDB buffer.
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
65007: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=65007
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: StrawberryTea <look <at> strawberrytea.xyz>
To: bug-gnu-emacs <at> gnu.org
Subject: [PATCH] Allow displaying program IO in the GDB buffer.
Date: Thu, 27 Jul 2023 20:33:39 -0400
* gdb-mi.el: Add new customizable variable `gdb-split-io-flag'.

This change allows the user to control whether program IO is displayed
in the GDB buffer or in a separate buffer.  The default is to display it
in the the `gdb-inferior-io' buffer.
---
 lisp/progmodes/gdb-mi.el | 16 +++++++++++++---
 1 file changed, 13 insertions(+), 3 deletions(-)

diff --git a/lisp/progmodes/gdb-mi.el b/lisp/progmodes/gdb-mi.el
index a1091de43e9..8f4f06abb9a 100644
--- a/lisp/progmodes/gdb-mi.el
+++ b/lisp/progmodes/gdb-mi.el
@@ -1098,9 +1098,10 @@ detailed description of this mode.
                      (if gdb-debuginfod-enable "on" "off"))
              'gdb-debuginfod-message)
 
-  (gdb-get-buffer-create 'gdb-inferior-io)
-  (gdb-clear-inferior-io)
-  (gdb-inferior-io--init-proc (get-process "gdb-inferior"))
+  (when gdb-split-io-flag
+    (gdb-get-buffer-create 'gdb-inferior-io)
+    (gdb-clear-inferior-io)
+    (gdb-inferior-io--init-proc (get-process "gdb-inferior")))
 
   (when (eq system-type 'windows-nt)
     ;; Don't create a separate console window for the debuggee.
@@ -1828,6 +1829,15 @@ this trigger is subscribed to `gdb-buf-publisher' and called with
   :group 'gdb
   :version "25.1")
 
+(defcustom gdb-split-io-flag t
+  "Non-nil means to split the program's I/O from the GDB buffer.
+
+If t, create the `gdb-inferior-io' buffer and redirect the
+program's I/O to it."
+  :type 'boolean
+  :group 'gdb
+  :version "30.1")
+
 (defun gdb-inferior-filter (proc string)
   (unless (string-equal string "")
     (let (buf)
-- 
2.41.0




[Message part 3 (message/rfc822, inline)]
From: Eli Zaretskii <eliz <at> gnu.org>
To: StrawberryTea <look <at> strawberrytea.xyz>
Cc: luangruo <at> yahoo.com, 65007-done <at> debbugs.gnu.org
Subject: Re: bug#65007: [PATCH] Allow displaying program IO in the GDB buffer.
Date: Sat, 16 Sep 2023 13:44:37 +0300
> From: StrawberryTea <look <at> strawberrytea.xyz>
> Cc: luangruo <at> yahoo.com, 65007 <at> debbugs.gnu.org
> Date: Sat, 16 Sep 2023 01:08:44 -0500
> 
> Yeah, I added `org-msg' and I have been trying to figure out how to send
> a patch with it. Probably I would need to put it in a source block. But
> I just turned that off

Thanks, installed on the master branch (with some changes), and
closing the bug.

With this patch, you exhausted the amount of changes we can accept
from you without a copyright assignment.  Would you like to start the
legal paperwork of assigning the copyright to the FSF at this time?
If yes, I will send you the form to fill and the instructions to email
the form.

Thanks.


This bug report was last modified 1 year and 246 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.