diff mbox

infcmd.c (attach_command): Improve comment.

Message ID yjt21tt397ge.fsf@ruffy.mtv.corp.google.com
State New
Headers show

Commit Message

Doug Evans July 29, 2014, 9:32 p.m. UTC
Hi.

I always have to re-lookup what target_attach_no_wait means,
and what targets set it to non-zero, every time I look at this code.

This patch is a modest attempt at clearing things up for me.
[maybe a good example of why double negatives should be avoided,
in this case "! no-wait".  maybe not.]

2014-07-29  Doug Evans  <dje@google.com>

	* infcmd.c (attach_command): Improve comment.

Comments

Pedro Alves July 30, 2014, 3:01 p.m. UTC | #1
On 07/29/2014 10:32 PM, Doug Evans wrote:
> Hi.
> 
> I always have to re-lookup what target_attach_no_wait means,
> and what targets set it to non-zero, every time I look at this code.
> 
> This patch is a modest attempt at clearing things up for me.
> [maybe a good example of why double negatives should be avoided,
> in this case "! no-wait".  maybe not.]

Looks obviously good to me.
diff mbox

Patch

diff --git a/gdb/infcmd.c b/gdb/infcmd.c
index d84c591..1def6cd 100644
--- a/gdb/infcmd.c
+++ b/gdb/infcmd.c
@@ -2578,7 +2578,7 @@  attach_command (char *args, int from_tty)
     }
 
   /* Some system don't generate traps when attaching to inferior.
-     E.g. Mach 3 or GNU hurd.  */
+     E.g. Mach 3 or GNU hurd.  Skip waiting for these targets.  */
   if (!target_attach_no_wait)
     {
       struct inferior *inferior = current_inferior ();