From e37709f0901fe6f2410094151002bab3d123df85 Mon Sep 17 00:00:00 2001 From: Frederic Cambus Date: Tue, 26 Jan 2021 09:55:34 +0000 Subject: Fix thinko in objcopy's memory freeing code. * objcopy.c (copy_main): Fix a double free happening when both --localize-symbols and --globalize-symbols options are invoked together. --- binutils/objcopy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'binutils/objcopy.c') diff --git a/binutils/objcopy.c b/binutils/objcopy.c index 62ee22202ff..a5cead1cf8e 100644 --- a/binutils/objcopy.c +++ b/binutils/objcopy.c @@ -6018,7 +6018,7 @@ copy_main (int argc, char *argv[]) free (keep_specific_buffer); if (localize_specific_buffer) - free (globalize_specific_buffer); + free (localize_specific_buffer); if (globalize_specific_buffer) free (globalize_specific_buffer); -- cgit v1.2.1