Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: "Ulrich Weigand" <uweigand@de.ibm.com>
To: brobecker@adacore.com (Joel Brobecker)
Cc: drow@false.org (Daniel Jacobowitz), gdb-patches@sources.redhat.com
Subject: [PATCH] Re: [RFC] Replace deprecated_target_new_objfile_hook by observer?
Date: Fri, 20 Oct 2006 00:41:00 -0000	[thread overview]
Message-ID: <200610200041.k9K0fcQF011121@d12av02.megacenter.de.ibm.com> (raw)
In-Reply-To: <20061019142951.GB1338@adacore.com> from "Joel Brobecker" at Oct 19, 2006 10:29:51 AM

Joel Brobecker wrote:

> Would you mind submitting your change for inclusion? I could then
> leverage off of this change for the transition to observers.

Sure, here goes the patch again.

Tested on s390-ibm-linux and s390x-ibm-linux.
OK for mainline?

Bye,
Ulrich


ChangeLog:

        * linux-thread-db.c (check_for_thread_db): Don't attempt to use
        thread_db for remote targets.
        * remote.c (remote_new_objfile): Always call predecessor on
        new_objfile event chain.

Index: gdb/linux-thread-db.c
===================================================================
RCS file: /cvs/src/src/gdb/linux-thread-db.c,v
retrieving revision 1.20
diff -u -p -r1.20 linux-thread-db.c
--- gdb/linux-thread-db.c	15 Oct 2006 19:38:45 -0000	1.20
+++ gdb/linux-thread-db.c	19 Oct 2006 20:08:44 -0000
@@ -599,6 +599,10 @@ check_for_thread_db (void)
   if (!target_has_execution)
     return;
 
+  /* Don't attempt to use thread_db for remote targets.  */
+  if (!target_can_run (&current_target))
+    return;
+
   /* Initialize the structure that identifies the child process.  */
   proc_handle.pid = GET_PID (inferior_ptid);
 
Index: gdb/remote.c
===================================================================
RCS file: /cvs/src/src/gdb/remote.c,v
retrieving revision 1.234
diff -u -p -r1.234 remote.c
--- gdb/remote.c	18 Oct 2006 16:56:13 -0000	1.234
+++ gdb/remote.c	19 Oct 2006 20:08:44 -0000
@@ -6126,8 +6126,7 @@ remote_new_objfile (struct objfile *objf
       remote_check_symbols (objfile);
     }
   /* Call predecessor on chain, if any.  */
-  if (remote_new_objfile_chain != 0 &&
-      remote_desc == 0)
+  if (remote_new_objfile_chain)
     remote_new_objfile_chain (objfile);
 }
 


-- 
  Dr. Ulrich Weigand
  Linux on zSeries Development
  Ulrich.Weigand@de.ibm.com


  reply	other threads:[~2006-10-20  0:41 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-10-17 23:32 Joel Brobecker
2006-10-17 23:35 ` Daniel Jacobowitz
2006-10-18  0:20   ` Joel Brobecker
2006-10-18  1:38     ` Daniel Jacobowitz
     [not found]       ` <535BF17A-E776-4DE4-979B-7E6FBA505E31@apple.com>
2006-10-18 17:11         ` Daniel Jacobowitz
2006-10-18 16:29   ` Ulrich Weigand
2006-10-18 16:43     ` Daniel Jacobowitz
2006-10-19 14:30     ` Joel Brobecker
2006-10-20  0:41       ` Ulrich Weigand [this message]
2006-10-20  0:46         ` [PATCH] " Daniel Jacobowitz
2006-10-20  1:09           ` Ulrich Weigand
2007-03-28 18:34       ` Ulrich Weigand
2007-03-28 18:42         ` Joel Brobecker

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200610200041.k9K0fcQF011121@d12av02.megacenter.de.ibm.com \
    --to=uweigand@de.ibm.com \
    --cc=brobecker@adacore.com \
    --cc=drow@false.org \
    --cc=gdb-patches@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox