]>
Commit | Line | Data |
---|---|---|
4b0e5c1b AM |
1 | From FEDORA_PATCHES Mon Sep 17 00:00:00 2001 |
2 | From: Fedora GDB patches <invalid@email.com> | |
3 | Date: Fri, 27 Oct 2017 21:07:50 +0200 | |
4 | Subject: gdb-6.6-buildid-locate-rpm-librpm-workaround.patch | |
5 | ||
4b0e5c1b AM |
6 | ;; Workaround librpm BZ 643031 due to its unexpected exit() calls (BZ 642879). |
7 | ;;=push+jan | |
4b0e5c1b AM |
8 | |
9 | diff --git a/gdb/build-id.c b/gdb/build-id.c | |
4b0e5c1b AM |
10 | --- a/gdb/build-id.c |
11 | +++ b/gdb/build-id.c | |
174fe25c | 12 | @@ -708,6 +708,19 @@ build_id_to_filename (const struct bfd_build_id *build_id, char **link_return) |
6ed6bacf AM |
13 | #include <dlfcn.h> |
14 | #endif | |
15 | ||
16 | +/* Workarodun https://bugzilla.redhat.com/show_bug.cgi?id=643031 | |
17 | + librpm must not exit() an application on SIGINT | |
18 | + | |
19 | + Enable or disable a signal handler. SIGNUM: signal to enable (or disable | |
20 | + if negative). HANDLER: sa_sigaction handler (or NULL to use | |
21 | + rpmsqHandler()). Returns: no. of refs, -1 on error. */ | |
a7de96f0 | 22 | +extern int rpmsqEnable (int signum, /* rpmsqAction_t handler */ void *handler); |
6ed6bacf AM |
23 | +int |
24 | +rpmsqEnable (int signum, /* rpmsqAction_t handler */ void *handler) | |
25 | +{ | |
26 | + return 0; | |
27 | +} | |
28 | + | |
29 | /* This MISSING_RPM_HASH tracker is used to collect all the missing rpm files | |
30 | and avoid their duplicities during a single inferior run. */ | |
31 | ||
4b0e5c1b | 32 | diff --git a/gdb/proc-service.list b/gdb/proc-service.list |
4b0e5c1b AM |
33 | --- a/gdb/proc-service.list |
34 | +++ b/gdb/proc-service.list | |
35 | @@ -37,4 +37,7 @@ | |
36 | ps_pstop; | |
37 | ps_ptread; | |
38 | ps_ptwrite; | |
39 | + | |
40 | + /* gdb-6.6-buildid-locate-rpm.patch */ | |
41 | + rpmsqEnable; | |
42 | }; |