summaryrefslogtreecommitdiff
path: root/libasm/asm_fill.c
diff options
context:
space:
mode:
authorDmitry V. Levin <ldv@altlinux.org>2021-09-06 08:00:00 +0000
committerDmitry V. Levin <ldv@altlinux.org>2021-09-09 08:01:00 +0000
commite094270980f1ca8af86a64cee0dbb6f1df670619 (patch)
tree1471f9586bb9e3d7f5448001353d47e94145a4ae /libasm/asm_fill.c
parent02b05e183998943dd5a19ba783b8793e2ab9ab44 (diff)
downloadelfutils-e094270980f1ca8af86a64cee0dbb6f1df670619.tar.gz
Remove redundant casts of memory allocating functions returning void *
Return values of functions returning "void *", e.g. calloc, malloc, realloc, xcalloc, xmalloc, and xrealloc, do not need explicit casts. Signed-off-by: Dmitry V. Levin <ldv@altlinux.org>
Diffstat (limited to 'libasm/asm_fill.c')
-rw-r--r--libasm/asm_fill.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/libasm/asm_fill.c b/libasm/asm_fill.c
index 62d9d732..783555ee 100644
--- a/libasm/asm_fill.c
+++ b/libasm/asm_fill.c
@@ -54,8 +54,7 @@ asm_fill (AsmScn_t *asmscn, void *bytes, size_t len)
else
{
/* Allocate appropriate memory. */
- pattern = (struct FillPattern *) malloc (sizeof (struct FillPattern)
- + len);
+ pattern = malloc (sizeof (struct FillPattern) + len);
if (pattern == NULL)
return -1;