forked from Imagelibrary/binutils-gdb
Replace uses of strncmp with memcmp
Avoids gcc pr85623 for these calls. * cofflink.c (_bfd_coff_link_input_bfd): Use memcmp rather than strncmp when checking for ".bf" special symbol. * prXXigen.c (_bfd_XXi_swap_scnhdr_out): Make pe_required_section_flags section name a char array, remove sentinal known_sections entry, and adjust loop over known_sections to suit. Use memcmp rather than strncmp.
This commit is contained in:
@@ -1839,7 +1839,7 @@ _bfd_coff_link_input_bfd (struct coff_final_link_info *flaginfo, bfd *input_bfd)
|
||||
|
||||
case C_FCN:
|
||||
if (obj_pe (input_bfd)
|
||||
&& strncmp (isym.n_name, ".bf", sizeof isym.n_name) != 0
|
||||
&& memcmp (isym.n_name, ".bf", sizeof ".bf") != 0
|
||||
&& isym.n_scnum > 0)
|
||||
{
|
||||
/* For PE, .lf and .ef get their value left alone,
|
||||
|
||||
Reference in New Issue
Block a user