aboutsummaryrefslogtreecommitdiffstats
path: root/fs/binfmt_elf.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/binfmt_elf.c')
-rw-r--r--fs/binfmt_elf.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/binfmt_elf.c b/fs/binfmt_elf.c
index 2f31c4c3fd48..3dc6a123fa10 100644
--- a/fs/binfmt_elf.c
+++ b/fs/binfmt_elf.c
@@ -52,7 +52,7 @@ static unsigned long elf_map (struct file *, unsigned long, struct elf_phdr *, i
52 * don't even try. 52 * don't even try.
53 */ 53 */
54#if defined(USE_ELF_CORE_DUMP) && defined(CONFIG_ELF_CORE) 54#if defined(USE_ELF_CORE_DUMP) && defined(CONFIG_ELF_CORE)
55static int elf_core_dump(long signr, struct pt_regs *regs, struct file *file); 55static int elf_core_dump(long signr, struct pt_regs *regs, struct file *file, unsigned long limit);
56#else 56#else
57#define elf_core_dump NULL 57#define elf_core_dump NULL
58#endif 58#endif
@@ -1488,7 +1488,7 @@ static struct vm_area_struct *next_vma(struct vm_area_struct *this_vma,
1488 * and then they are actually written out. If we run out of core limit 1488 * and then they are actually written out. If we run out of core limit
1489 * we just truncate. 1489 * we just truncate.
1490 */ 1490 */
1491static int elf_core_dump(long signr, struct pt_regs *regs, struct file *file) 1491static int elf_core_dump(long signr, struct pt_regs *regs, struct file *file, unsigned long limit)
1492{ 1492{
1493#define NUM_NOTES 6 1493#define NUM_NOTES 6
1494 int has_dumped = 0; 1494 int has_dumped = 0;
@@ -1499,7 +1499,6 @@ static int elf_core_dump(long signr, struct pt_regs *regs, struct file *file)
1499 struct vm_area_struct *vma, *gate_vma; 1499 struct vm_area_struct *vma, *gate_vma;
1500 struct elfhdr *elf = NULL; 1500 struct elfhdr *elf = NULL;
1501 loff_t offset = 0, dataoff, foffset; 1501 loff_t offset = 0, dataoff, foffset;
1502 unsigned long limit = current->signal->rlim[RLIMIT_CORE].rlim_cur;
1503 int numnote; 1502 int numnote;
1504 struct memelfnote *notes = NULL; 1503 struct memelfnote *notes = NULL;
1505 struct elf_prstatus *prstatus = NULL; /* NT_PRSTATUS */ 1504 struct elf_prstatus *prstatus = NULL; /* NT_PRSTATUS */