summaryrefslogtreecommitdiff
path: root/packages/binutils/2.37/0017-pr28540-segmentation-fault-on-NULL-byte_get.patch
diff options
context:
space:
mode:
authorHans-Christian Noren Egtvedt <hegtvedt@cisco.com>2022-02-02 18:14:39 (GMT)
committerChris Packham <judge.packham@gmail.com>2022-02-03 20:55:25 (GMT)
commit5a4c95d658eddaf7e7cd3b4c2951875a8e427e2e (patch)
tree5556b6fdab05cb41960bf40da5d20e3e128c6e46 /packages/binutils/2.37/0017-pr28540-segmentation-fault-on-NULL-byte_get.patch
parent392955a293573451baf3a9294139d0558b08ca2e (diff)
binutils-2.37: add more patches from upstream release branch
Fetch in various patches from binutils-2_37-branch upstream. The most vital change is the 0012-pr28391-strip-objcopy-preserve-dates-a-cannot-set-time.patch which allows building large upstream projects like Qt WebEngine without need 100k's of file descriptors open. Signed-off-by: Hans-Christian Noren Egtvedt <hegtvedt@cisco.com>
Diffstat (limited to 'packages/binutils/2.37/0017-pr28540-segmentation-fault-on-NULL-byte_get.patch')
-rw-r--r--packages/binutils/2.37/0017-pr28540-segmentation-fault-on-NULL-byte_get.patch30
1 files changed, 30 insertions, 0 deletions
diff --git a/packages/binutils/2.37/0017-pr28540-segmentation-fault-on-NULL-byte_get.patch b/packages/binutils/2.37/0017-pr28540-segmentation-fault-on-NULL-byte_get.patch
new file mode 100644
index 0000000..f7f26a7
--- /dev/null
+++ b/packages/binutils/2.37/0017-pr28540-segmentation-fault-on-NULL-byte_get.patch
@@ -0,0 +1,30 @@
+From 96eb21265ebffbc28f767bed9a2b7650ecb9818d Mon Sep 17 00:00:00 2001
+From: Alan Modra <amodra@gmail.com>
+Date: Thu, 4 Nov 2021 14:11:02 +1030
+Subject: [PATCH] PR28540, segmentation fault on NULL byte_get
+
+ PR 28540
+ * objdump.c (dump_bfd): Don't attempt load_separate_debug_files
+ when byte_get is NULL.
+
+(cherry picked from commit f2f105f518413ea3e4c212f89585f9a8a5dddcdd)
+---
+ binutils/objdump.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/binutils/objdump.c b/binutils/objdump.c
+index a7b8303b992..50317b3d48f 100644
+--- a/binutils/objdump.c
++++ b/binutils/objdump.c
+@@ -4869,7 +4869,7 @@ dump_bfd (bfd *abfd, bool is_mainfile)
+
+ The test on is_mainfile is there because the chain of separate debug
+ info files is a global variable shared by all invocations of dump_bfd. */
+- if (is_mainfile)
++ if (byte_get != NULL && is_mainfile)
+ {
+ load_separate_debug_files (abfd, bfd_get_filename (abfd));
+
+--
+2.27.0
+