From c4c50d37408542b33e29eb64ae2007d2de6aa554 Mon Sep 17 00:00:00 2001 From: Daniel Jacobowitz Date: Thu, 11 May 2006 19:37:52 +0000 Subject: 2006-05-11 Alfred M. Szmidt * gnu-nat.c (inf_validate_procs): Don't use lvalue in assignments. --- gdb/gnu-nat.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'gdb/gnu-nat.c') diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c index f17d001..968a9cf 100644 --- a/gdb/gnu-nat.c +++ b/gdb/gnu-nat.c @@ -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. */ -- cgit v1.1