summaryrefslogtreecommitdiff
path: root/src/libelfu/modelops/layout.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libelfu/modelops/layout.c')
-rw-r--r--src/libelfu/modelops/layout.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/src/libelfu/modelops/layout.c b/src/libelfu/modelops/layout.c
index 2fd610c..182ed2e 100644
--- a/src/libelfu/modelops/layout.c
+++ b/src/libelfu/modelops/layout.c
@@ -345,7 +345,6 @@ int elfu_mLayoutAuto(ElfuElf *me)
ElfuPhdr *highestOffsEnd;
ElfuPhdr *mp;
ElfuScn *ms;
- ElfuPhdr **phdrArr;
GElf_Off lastend = 0;
assert(me);
@@ -354,12 +353,6 @@ int elfu_mLayoutAuto(ElfuElf *me)
elfu_mPhdrLoadLowestHighest(me, &lowestAddr, &highestAddr,
&lowestOffs, &highestOffsEnd);
- phdrArr = malloc(elfu_mPhdrCount(me) * sizeof(*phdrArr));
- if (!phdrArr) {
- ELFU_WARN("elfu_mLayoutAuto: malloc failed for phdrArr.\n");
- return 1;
- }
-
lastend = OFFS_END(highestOffsEnd->phdr.p_offset, highestOffsEnd->phdr.p_filesz);