projects
/
deliverable
/
binutils-gdb.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Revert 'Remove unused struct serial::name field'
[deliverable/binutils-gdb.git]
/
bfd
/
elf-properties.c
diff --git
a/bfd/elf-properties.c
b/bfd/elf-properties.c
index 94ef2351cb632828c66127907137e7d523cb719d..76ddad603711112dcac702aaa3fe16eb9dd3d89d 100644
(file)
--- a/
bfd/elf-properties.c
+++ b/
bfd/elf-properties.c
@@
-1,5
+1,5
@@
/* ELF program property support.
/* ELF program property support.
- Copyright (C) 2017-20
19
Free Software Foundation, Inc.
+ Copyright (C) 2017-20
20
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
This file is part of BFD, the Binary File Descriptor library.
@@
-236,12
+236,12
@@
elf_merge_gnu_properties (struct bfd_link_info *info, bfd *abfd, bfd *bbfd,
return FALSE;
}
return FALSE;
}
-/* Return the property of TYPE on *LISTP and remove it from *LISTP
.
- Return NULL if not found. */
+/* Return the property of TYPE on *LISTP and remove it from *LISTP
if RM is
+
true.
Return NULL if not found. */
static elf_property *
elf_find_and_remove_property (elf_property_list **listp,
static elf_property *
elf_find_and_remove_property (elf_property_list **listp,
- unsigned int type, bfd_boolean r
emove
)
+ unsigned int type, bfd_boolean r
m
)
{
elf_property_list *list;
{
elf_property_list *list;
@@
-250,7
+250,7
@@
elf_find_and_remove_property (elf_property_list **listp,
if (type == list->property.pr_type)
{
/* Remove this property. */
if (type == list->property.pr_type)
{
/* Remove this property. */
- if (r
emove
)
+ if (r
m
)
*listp = list->next;
return &list->property;
}
*listp = list->next;
return &list->property;
}
@@
-322,12
+322,10
@@
elf_merge_gnu_property_list (struct bfd_link_info *info, bfd *first_pbfd,
(bfd_vma) p->property.pr_type, first_pbfd, abfd);
}
}
(bfd_vma) p->property.pr_type, first_pbfd, abfd);
}
}
- else
- {
- /* Remove this property. */
- *lastp = p->next;
- continue;
- }
+
+ /* Remove this property. */
+ *lastp = p->next;
+ continue;
}
else if (number_p)
{
}
else if (number_p)
{
@@
-697,14
+695,16
@@
_bfd_elf_convert_gnu_properties (bfd *ibfd, asection *isec,
align_shift = bed->s->elfclass == ELFCLASS64 ? 3 : 2;
/* Get the output .note.gnu.property section size. */
align_shift = bed->s->elfclass == ELFCLASS64 ? 3 : 2;
/* Get the output .note.gnu.property section size. */
- size = bfd_
get_
section_size (isec->output_section);
+ size = bfd_section_size (isec->output_section);
/* Update the output .note.gnu.property section alignment. */
/* Update the output .note.gnu.property section alignment. */
- bfd_set_section_alignment (
obfd,
isec->output_section, align_shift);
+ bfd_set_section_alignment (isec->output_section, align_shift);
- if (size > bfd_
get_
section_size (isec))
+ if (size > bfd_section_size (isec))
{
contents = (bfd_byte *) bfd_malloc (size);
{
contents = (bfd_byte *) bfd_malloc (size);
+ if (contents == NULL)
+ return FALSE;
free (*ptr);
*ptr = contents;
}
free (*ptr);
*ptr = contents;
}
This page took
0.02399 seconds
and
4
git commands to generate.