From 780f96aed2b4db1014e8fa2b50118676d8af0e46 Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Sat, 14 Mar 2020 11:50:22 +1030 Subject: readelf large memory allocation * elfcomm.h (setup_archive): Update prototype. * elfcomm.c (setup_archive): Add file_size parameter and sanity check longnames_size. (setup_nested_archive): Get file size and pass to setup_archive. * elfedit.c (process_archive): Likewise. * readelf.c (process_archive): Pass filedata->file_size to setup_archive. --- binutils/elfcomm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'binutils/elfcomm.h') diff --git a/binutils/elfcomm.h b/binutils/elfcomm.h index 9bf3c41..731d3db 100644 --- a/binutils/elfcomm.h +++ b/binutils/elfcomm.h @@ -74,7 +74,7 @@ extern char *adjust_relative_path (const char *, const char *, unsigned long); /* Read the symbol table and long-name table from an archive. */ extern int setup_archive (struct archive_info *, const char *, FILE *, - bfd_boolean, bfd_boolean); + bfd_size_type, bfd_boolean, bfd_boolean); /* Open and setup a nested archive, if not already open. */ extern int setup_nested_archive (struct archive_info *, const char *); -- cgit v1.1