Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* Fix Hurd build
@ 2006-05-11 19:39 Daniel Jacobowitz
  2006-05-11 19:42 ` Alfred M. Szmidt
  0 siblings, 1 reply; 2+ messages in thread
From: Daniel Jacobowitz @ 2006-05-11 19:39 UTC (permalink / raw)
  To: gdb-patches; +Cc: ams

I've committed this patch from Alfred Szmidt.  Alfred, as you've noticed,
the GNATS database is not a useful way to submit patches; in addition to
being infrequently checked, it mangles unencoded attachments severely.
If you have future bugfixes for the GNU system, might I recommend posting
them to gdb-patches instead?

-- 
Daniel Jacobowitz
CodeSourcery

2006-05-11  Alfred M. Szmidt  <ams@gnu.org>

	* gnu-nat.c (inf_validate_procs): Don't use lvalue in assignments.

Index: gnu-nat.c
===================================================================
RCS file: /cvs/src/src/gdb/gnu-nat.c,v
retrieving revision 1.39
diff -u -p -r1.39 gnu-nat.c
--- gnu-nat.c	24 Jan 2006 22:09:28 -0000	1.39
+++ gnu-nat.c	11 May 2006 19:36:55 -0000
@@ -1050,7 +1050,10 @@ inf_validate_procs (struct inf *inf)
 	    proc_debug (thread, "died!");
 	    thread->port = MACH_PORT_NULL;
 	    thread = _proc_free (thread);	/* THREAD is dead.  */
-	    (last ? last->next : inf->threads) = thread;
+	    if (last)
+	      last->next = thread;
+	    else
+	      inf->threads = thread;
 	  }
       }
 
@@ -1063,7 +1066,10 @@ inf_validate_procs (struct inf *inf)
 	  /* THREADS[I] is a thread we don't know about yet!  */
 	  {
 	    thread = make_proc (inf, threads[i], next_thread_id++);
-	    (last ? last->next : inf->threads) = thread;
+	    if (last)
+	      last->next = thread;
+	    else
+	      inf->threads = thread;
 	    last = thread;
 	    proc_debug (thread, "new thread: %d", threads[i]);
 	    add_thread (pid_to_ptid (thread->tid));	/* Tell GDB's generic thread code.  */


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-05-11 19:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-05-11 19:39 Fix Hurd build Daniel Jacobowitz
2006-05-11 19:42 ` Alfred M. Szmidt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox