Blame SOURCES/gdb-moribund-utrace-workaround.patch

5ad05e
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
5ad05e
From: Fedora GDB patches <invalid@email.com>
5ad05e
Date: Fri, 27 Oct 2017 21:07:50 +0200
5ad05e
Subject: gdb-moribund-utrace-workaround.patch
5ad05e
5ad05e
;; Workaround non-stop moribund locations exploited by kernel utrace (BZ 590623).
5ad05e
;;=push+jan: Currently it is still not fully safe.
5ad05e
5ad05e
https://bugzilla.redhat.com/show_bug.cgi?id=590623
5ad05e
http://sources.redhat.com/bugzilla/show_bug.cgi?id=11593
5ad05e
5ad05e
Bug in FSF GDB exploited by the ptrace-on-utrace interaction.
5ad05e
5ad05e
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
5ad05e
--- a/gdb/breakpoint.c
5ad05e
+++ b/gdb/breakpoint.c
5ad05e
@@ -11904,6 +11904,8 @@ update_global_location_list (enum ugll_insert_mode insert_mode)
5ad05e
 		 traps we can no longer explain.  */
5ad05e
 
5ad05e
 	      old_loc->events_till_retirement = 3 * (thread_count () + 1);
5ad05e
+	      /* Red Hat Bug 590623.  */
5ad05e
+	      old_loc->events_till_retirement *= 10;
5ad05e
 	      old_loc->owner = NULL;
5ad05e
 
5ad05e
 	      moribund_locations.push_back (old_loc);