Module Name: src
Committed By: christos
Date: Wed Mar 21 23:20:58 UTC 2012
Modified Files:
src/external/gpl3/gdb/dist/gdb: nbsd-thread.c
Log Message:
Use tid - 1 for the thread id, so that thread 1 matches the main thread
before the threaded code gets loaded. fixes spurious breakpoints. Is
there a better way?
To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/external/gpl3/gdb/dist/gdb/nbsd-thread.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/external/gpl3/gdb/dist/gdb/nbsd-thread.c
diff -u src/external/gpl3/gdb/dist/gdb/nbsd-thread.c:1.9 src/external/gpl3/gdb/dist/gdb/nbsd-thread.c:1.10
--- src/external/gpl3/gdb/dist/gdb/nbsd-thread.c:1.9 Sun Feb 5 12:40:48 2012
+++ src/external/gpl3/gdb/dist/gdb/nbsd-thread.c Wed Mar 21 19:20:58 2012
@@ -90,7 +90,7 @@ static void nbsd_find_new_threads (struc
#define IS_LWP(ptid) (GET_LWP (ptid) != 0)
#define IS_THREAD(ptid) (GET_THREAD (ptid) != 0)
-#define BUILD_LWP(lwp, ptid) ptid_build (GET_PID(ptid), lwp, 0)
+#define BUILD_LWP(lwp, ptid) ptid_build (GET_PID(ptid), (lwp) - 1, 0)
#define BUILD_THREAD(tid, ptid) ptid_build (GET_PID(ptid), 0, tid)
static td_proc_t *main_ta;