Skip to content

Commit 2beef70

Browse files
W-M-Rxiaoxiang781216
authored andcommitted
coredump.c: del multiple behavior
Signed-off-by: wangmingrong1 <[email protected]>
1 parent c350644 commit 2beef70

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

sched/misc/coredump.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -554,7 +554,6 @@ static void elf_emit_tcb_phdr(FAR struct elf_dumpinfo_s *cinfo,
554554
phdr->p_paddr = phdr->p_vaddr;
555555
phdr->p_memsz = phdr->p_filesz;
556556
phdr->p_flags = PF_X | PF_W | PF_R;
557-
phdr->p_align = ELF_PAGESIZE;
558557
*offset += ROUNDUP(phdr->p_memsz, ELF_PAGESIZE);
559558

560559
elf_emit(cinfo, phdr, sizeof(*phdr));
@@ -585,6 +584,7 @@ static void elf_emit_phdr(FAR struct elf_dumpinfo_s *cinfo,
585584

586585
elf_emit(cinfo, &phdr, sizeof(phdr));
587586

587+
phdr.p_align = ELF_PAGESIZE;
588588
if (cinfo->pid == INVALID_PROCESS_ID)
589589
{
590590
for (i = 0; i < g_npidhash; i++)
@@ -612,7 +612,6 @@ static void elf_emit_phdr(FAR struct elf_dumpinfo_s *cinfo,
612612
phdr.p_filesz = cinfo->regions[i].end - cinfo->regions[i].start;
613613
phdr.p_memsz = phdr.p_filesz;
614614
phdr.p_flags = cinfo->regions[i].flags;
615-
phdr.p_align = ELF_PAGESIZE;
616615
offset += ROUNDUP(phdr.p_memsz, ELF_PAGESIZE);
617616
elf_emit(cinfo, &phdr, sizeof(phdr));
618617
}

0 commit comments

Comments
 (0)