aboutsummaryrefslogtreecommitdiff
path: root/fs/binfmt_elf.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-07-01 09:56:10 +0200
committerIngo Molnar <mingo@elte.hu>2009-07-01 09:56:26 +0200
commit087021ba41e9481202103d51d3dd0c4706899a2b (patch)
treebf5d67420fd176682a1f8f1e9342ad397c23937a /fs/binfmt_elf.c
parentfb9c818873a788c5c01c9868cc6050df96e2c7df (diff)
parente83c2b0ff325f52dda1aff3572d0e1516216c54b (diff)
Merge branch 'linus' into perfcounters/urgent
Merge reason: this branch was on a .30-ish base before, update it to an almost-.31-rc2 upstream base to pick up fixes. Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'fs/binfmt_elf.c')
-rw-r--r--fs/binfmt_elf.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/binfmt_elf.c b/fs/binfmt_elf.c
index 9fa212b014a..f1867900e45 100644
--- a/fs/binfmt_elf.c
+++ b/fs/binfmt_elf.c
@@ -1929,7 +1929,10 @@ static int elf_core_dump(long signr, struct pt_regs *regs, struct file *file, un
elf = kmalloc(sizeof(*elf), GFP_KERNEL);
if (!elf)
goto out;
-
+ /*
+ * The number of segs are recored into ELF header as 16bit value.
+ * Please check DEFAULT_MAX_MAP_COUNT definition when you modify here.
+ */
segs = current->mm->map_count;
#ifdef ELF_CORE_EXTRA_PHDRS
segs += ELF_CORE_EXTRA_PHDRS;