diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2020-02-11 04:26:00 -0800 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2020-02-11 04:27:27 -0800 |
commit | 1d07a805c8ffb611b1ee21b30dd16f10ff8b11bf (patch) | |
tree | 1e3774c1d684e4b756df57b352204aeb7aa6bf66 /bfd | |
parent | 50128d0cab8445e97ee89f55082dadb69d2bfbc8 (diff) | |
download | binutils-1d07a805c8ffb611b1ee21b30dd16f10ff8b11bf.zip binutils-1d07a805c8ffb611b1ee21b30dd16f10ff8b11bf.tar.gz binutils-1d07a805c8ffb611b1ee21b30dd16f10ff8b11bf.tar.bz2 |
Clear plugin_data memory
Clear plugin_data memory since it may be uninitialized.
* plugin.c (add_symbols): Clear plugin_data memory.
Diffstat (limited to 'bfd')
-rw-r--r-- | bfd/ChangeLog | 4 | ||||
-rw-r--r-- | bfd/plugin.c | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index fef8bc4..57b1959 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,7 @@ +2020-02-11 H.J. Lu <hongjiu.lu@intel.com> + + * plugin.c (add_symbols): Clear plugin_data memory. + 2020-02-10 H.J. Lu <hongjiu.lu@intel.com> PR binutils/25355 diff --git a/bfd/plugin.c b/bfd/plugin.c index 1edcb57..5681a6a 100644 --- a/bfd/plugin.c +++ b/bfd/plugin.c @@ -448,6 +448,8 @@ add_symbols (void * handle, size_t sym_info_size, name_length; int i; + memset (plugin_data, 0, sizeof (*plugin_data)); + abfd->tdata.plugin_data = plugin_data; /* NB: LTO symbols are owned by LTO plugin. Create a copy so |