binutils/binutils-CVE-38128-dwarf-abbrev-parsing.patch
yahmad f44b483e75 - Fic configuration of s390x binutils so that it does not include support for extraneous targets. (#2139143)
- Fix readelf's decoding of files with no sections.  (#2131609)
- Stop potential infinite loop in the binutils DWARF parser.  (#2122675)
2022-11-17 16:07:26 +01:00

16 lines
463 B
Diff

--- binutils.orig/binutils/dwarf.c 2022-08-31 11:58:08.918685348 +0100
+++ binutils-2.39/binutils/dwarf.c 2022-08-31 15:24:13.881865797 +0100
@@ -6365,7 +6365,11 @@ display_debug_abbrev (struct dwarf_secti
list->start_of_next_abbrevs = start;
}
else
- start = list->start_of_next_abbrevs;
+ {
+ if (start == list->start_of_next_abbrevs)
+ break;
+ start = list->start_of_next_abbrevs;
+ }
if (list->first_abbrev == NULL)
continue;