ports/devel/gdb/files/patch-gdb_fbsd-nat.c
Luca Pizzamiglio da0888d129 devel/gdb: Update to gdb 8.0.1
Resolve tons of warnings.
Fix the type of literal string as char const *
Fix Makefile's variables order and adding the license file
Rework patches to make portlint happy

Reviewed by:	jhb
Approved by:	lme (mentor)
Differential Revision:	https://reviews.freebsd.org/D12525
2017-09-29 14:49:58 +00:00

17 lines
657 B
C

--- gdb/fbsd-nat.c.orig 2017-09-14 09:28:17 UTC
+++ gdb/fbsd-nat.c
@@ -682,6 +682,14 @@ fbsd_resume (struct target_ops *ops,
struct thread_info *tp;
int request;
+#ifndef PT_LWP_EVENTS
+ /* When LWP events are not supported, a new thread might already be
+ running that has not yet reported an event when GDB wishes to
+ only run a single thread. Force an update of the thread list
+ to ensure that any such threads are suspended before the process
+ is resumed. */
+ fbsd_add_threads (ptid_get_pid (ptid));
+#endif
ALL_NON_EXITED_THREADS (tp)
{
if (ptid_get_pid (tp->ptid) != ptid_get_pid (ptid))