Backport binutils/29969 "Fix an illegal memory access when parsing..."
Resolves: rhbz#2153228
This commit is contained in:
parent
86ee11836e
commit
9c34980768
@ -284,3 +284,7 @@ Patch067: gdb-gcc-13-backport-self-move-diagnostic-fix
|
||||
# (Simon Marchi, backtrace/29374)
|
||||
Patch068: gdb-backport-call-check_typedef-at-beginning-of-dwarf_expr_context.patch
|
||||
|
||||
# Backport "Fix an illegal memory access when parsing..."
|
||||
# (Nick Clifton, RHBZ 2153228)
|
||||
Patch069: gdb-rhbz2153228-fail-if-sh_info-is-zero.patch
|
||||
|
||||
|
@ -66,3 +66,4 @@
|
||||
%patch066 -p1
|
||||
%patch067 -p1
|
||||
%patch068 -p1
|
||||
%patch069 -p1
|
||||
|
@ -65,4 +65,5 @@ gdb-rhbz2143992-libiberty-fix-c89isms-in-configure.patch
|
||||
gdb-rhbz2152431-label-symbol-value.patch
|
||||
gdb-backport-python-config-replace-deprecated-distutils.patch
|
||||
gdb-gcc-13-backport-self-move-diagnostic-fix
|
||||
gdb-backport-call-check_typedef-at-beginning-of-dwarf_expr_context.patch
|
||||
gdb-backport-call-check_typedef-at-beginning-of-dwarf_expr_context.patch
|
||||
gdb-rhbz2153228-fail-if-sh_info-is-zero.patch
|
||||
|
26
gdb-rhbz2153228-fail-if-sh_info-is-zero.patch
Normal file
26
gdb-rhbz2153228-fail-if-sh_info-is-zero.patch
Normal file
@ -0,0 +1,26 @@
|
||||
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
|
||||
From: Nick Clifton <nickc@redhat.com>
|
||||
Date: Wed, 19 Oct 2022 15:09:12 +0100
|
||||
Subject: gdb-rhbz2153228-fail-if-sh_info-is-zero.patch
|
||||
|
||||
;; Backport "Fix an illegal memory access when parsing..."
|
||||
;; (Nick Clifton, RHBZ 2153228)
|
||||
|
||||
PR 29699
|
||||
* elf.c (_bfd_elf_slurp_version_tables): Fail if the sh_info field
|
||||
of the section header is zero.
|
||||
|
||||
diff --git a/bfd/elf.c b/bfd/elf.c
|
||||
--- a/bfd/elf.c
|
||||
+++ b/bfd/elf.c
|
||||
@@ -8832,7 +8832,9 @@ _bfd_elf_slurp_version_tables (bfd *abfd, bool default_imported_symver)
|
||||
bfd_set_error (bfd_error_file_too_big);
|
||||
goto error_return_verref;
|
||||
}
|
||||
- elf_tdata (abfd)->verref = (Elf_Internal_Verneed *) bfd_alloc (abfd, amt);
|
||||
+ if (amt == 0)
|
||||
+ goto error_return_verref;
|
||||
+ elf_tdata (abfd)->verref = (Elf_Internal_Verneed *) bfd_zalloc (abfd, amt);
|
||||
if (elf_tdata (abfd)->verref == NULL)
|
||||
goto error_return_verref;
|
||||
|
6
gdb.spec
6
gdb.spec
@ -69,7 +69,7 @@ Version: 12.1
|
||||
|
||||
# The release always contains a leading reserved number, start it at 1.
|
||||
# `upstream' is not a part of `name' to stay fully rpm dependencies compatible for the testing.
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
|
||||
License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ and GPLv2+ with exceptions and GPL+ and LGPLv2+ and LGPLv3+ and BSD and Public Domain and GFDL
|
||||
# Do not provide URL for snapshots as the file lasts there only for 2 days.
|
||||
@ -1201,6 +1201,10 @@ fi
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Thu Apr 27 2023 Keith Seitz <keiths@redhat.com> - 12.1-2.el9
|
||||
- Backport binutls/29699 "Fix an illegal memory access when parsing..."
|
||||
(Nick Clifton, RHBZ 2153228)
|
||||
|
||||
* Tue Apr 18 2023 Keith Seitz <keiths@redhat.com> - 12.1-1.el9
|
||||
- Initial import for GTS13.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user