Index: gdb/gdbserver/nto-low.c |
diff --git a/gdb/gdbserver/nto-low.c b/gdb/gdbserver/nto-low.c |
index 73618cdd29006c8207eeb9c57d0f5dd0fe722ca5..6f764ff5e214dad68fe9fca1de55e67e8951c9bb 100644 |
--- a/gdb/gdbserver/nto-low.c |
+++ b/gdb/gdbserver/nto-low.c |
@@ -1,6 +1,6 @@ |
/* QNX Neutrino specific low level interface, for the remote server |
for GDB. |
- Copyright (C) 2009-2012 Free Software Foundation, Inc. |
+ Copyright (C) 2009-2013 Free Software Foundation, Inc. |
This file is part of GDB. |
@@ -21,6 +21,7 @@ |
#include "server.h" |
#include "gdbthread.h" |
#include "nto-low.h" |
+#include "hostio.h" |
#include <limits.h> |
#include <fcntl.h> |
@@ -35,6 +36,8 @@ |
extern int using_threads; |
int using_threads = 1; |
+const struct target_desc *nto_tdesc; |
+ |
static void |
nto_trace (const char *fmt, ...) |
{ |
@@ -203,11 +206,13 @@ do_attach (pid_t pid) |
&& (status.flags & _DEBUG_FLAG_STOPPED)) |
{ |
ptid_t ptid; |
+ struct process_info *proc; |
kill (pid, SIGCONT); |
ptid = ptid_build (status.pid, status.tid, 0); |
the_low_target.arch_setup (); |
- add_process (status.pid, 1); |
+ proc = add_process (status.pid, 1); |
+ proc->tdesc = nto_tdesc; |
TRACE ("Adding thread: pid=%d tid=%ld\n", status.pid, |
ptid_get_lwp (ptid)); |
nto_find_new_threads (&nto_inferior); |