Message ID | DB4PR02MB2729B8E783A3B6A4449F06CD6AF0@DB4PR02MB272.eurprd02.prod.outlook.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
diff --git a/fs/binfmt_elf.c b/fs/binfmt_elf.c index 241ef68..09f9483 100644 --- a/fs/binfmt_elf.c +++ b/fs/binfmt_elf.c @@ -962,6 +962,9 @@ static int load_elf_binary(struct linux_binprm *bprm) k = elf_ppnt->p_vaddr + elf_ppnt->p_filesz; + if (k >= STACK_TOP) + continue; + if (k > elf_bss) elf_bss = k; if ((elf_ppnt->p_flags & PF_X) && end_code < k)