Fix uninitialised memory acccess in COFF bfd backend

2018-05-15  Christophe Guillon  <christophe.guillon@st.com>

	* coffcode.h (coff_bigobj_swap_aux_in): Make sure that all fields
	of the aux structure are initialised.

Change-Id: I81be255ac6611afbe00995fac550e98e6a07e5df
This commit is contained in:
Christophe Guillon
2018-05-15 12:27:45 +00:00
committed by Christophe Lyon
parent 1678bd35a3
commit 810ed4db98
2 changed files with 8 additions and 0 deletions

View File

@ -5528,6 +5528,9 @@ coff_bigobj_swap_aux_in (bfd *abfd,
AUXENT_BIGOBJ *ext = (AUXENT_BIGOBJ *) ext1;
union internal_auxent *in = (union internal_auxent *) in1;
/* Make sure that all fields in the aux structure are
initialised. */
memset (in, 0, sizeof * in);
switch (in_class)
{
case C_FILE: