Re: Multi-packet gdb server request/response - problem?
Pedro Alves <[email protected]>
| Newsgroups | gmane.comp.gdb.devel |
|---|---|
| Message-ID | <[email protected]> |
On 12/12/2013 03:44 PM, Ivo Raisr wrote:
> At some point in the debugging session (not sure when but it does not matter),
> I think gdb kicks in the OS-specific functions. For solaris, they are
> found in sol-thread.c.
That's the (or a) problem. They shouldn't. sol-thread.c should only
be active for native Solaris debugging. Try this.
---
gdb/sol-thread.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/gdb/sol-thread.c b/gdb/sol-thread.c
index b480b58..3809aec 100644
--- a/gdb/sol-thread.c
+++ b/gdb/sol-thread.c
@@ -578,6 +578,10 @@ check_for_thread_db (void)
td_err_e err;
ptid_t ptid;
+ /* Don't attempt to use thread_db for remote targets. */
+ if (!(target_can_run (¤t_target) || core_bfd))
+ return;
+
/* Do nothing if we couldn't load libthread_db.so.1. */
if (p_td_ta_new == NULL)
return;
--
1.7.11.7