summaryrefslogtreecommitdiff
path: root/libelf/elf_newscn.c
diff options
context:
space:
mode:
authorMark Wielaard <mark@klomp.org>2022-05-10 15:22:32 +0200
committerMark Wielaard <mark@klomp.org>2022-05-10 15:22:32 +0200
commite06d1d2530fa5d7eb898f3114d282bd196315d55 (patch)
tree1db2efd48765f9dc4c7e72abd936f860c1a9c9c5 /libelf/elf_newscn.c
parente00652f54afca62c5facbaddebe21012acd43386 (diff)
parent059e690e896e37c16774047bd1fd0c9e608545b8 (diff)
downloadelfutils-e06d1d2530fa5d7eb898f3114d282bd196315d55.tar.gz
Merge tag 'elfutils-0.187' into mjw/RH-DTSmjw/RH-DTS
elfutils 0.187 release
Diffstat (limited to 'libelf/elf_newscn.c')
-rw-r--r--libelf/elf_newscn.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/libelf/elf_newscn.c b/libelf/elf_newscn.c
index d15a642e..d6bdf153 100644
--- a/libelf/elf_newscn.c
+++ b/libelf/elf_newscn.c
@@ -94,9 +94,9 @@ elf_newscn (Elf *elf)
1
#endif
)
- newp = (Elf_ScnList *) calloc (sizeof (Elf_ScnList)
- + ((elf->state.elf.scnincr *= 2)
- * sizeof (Elf_Scn)), 1);
+ newp = calloc (sizeof (Elf_ScnList)
+ + ((elf->state.elf.scnincr *= 2)
+ * sizeof (Elf_Scn)), 1);
if (newp == NULL)
{
__libelf_seterrno (ELF_E_NOMEM);
@@ -122,7 +122,7 @@ elf_newscn (Elf *elf)
/* Create a section header for this section. */
if (elf->class == ELFCLASS32)
{
- result->shdr.e32 = (Elf32_Shdr *) calloc (1, sizeof (Elf32_Shdr));
+ result->shdr.e32 = calloc (1, sizeof (Elf32_Shdr));
if (result->shdr.e32 == NULL)
{
__libelf_seterrno (ELF_E_NOMEM);
@@ -131,7 +131,7 @@ elf_newscn (Elf *elf)
}
else
{
- result->shdr.e64 = (Elf64_Shdr *) calloc (1, sizeof (Elf64_Shdr));
+ result->shdr.e64 = calloc (1, sizeof (Elf64_Shdr));
if (result->shdr.e64 == NULL)
{
__libelf_seterrno (ELF_E_NOMEM);