Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 39622
b: refs/heads/master
c: a7a0d86
h: refs/heads/master
v: v3
  • Loading branch information
Petr Vandrovec authored and Linus Torvalds committed Oct 15, 2006
1 parent d0c8679 commit 977b1eb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0b269d8462a9f0058afb46eaee56e0732acf16c4
refs/heads/master: a7a0d86f5aa40a2215e36fe21d7911cf718ba428
8 changes: 3 additions & 5 deletions trunk/fs/binfmt_elf.c
Original file line number Diff line number Diff line change
Expand Up @@ -1220,7 +1220,7 @@ static int notesize(struct memelfnote *en)

static int alignfile(struct file *file, loff_t *foffset)
{
char buf[4] = { 0, };
static const char buf[4] = { 0, };
DUMP_WRITE(buf, roundup(*foffset, 4) - *foffset, foffset);
return 1;
}
Expand Down Expand Up @@ -1569,7 +1569,8 @@ static int elf_core_dump(long signr, struct pt_regs *regs, struct file *file)

DUMP_WRITE(elf, sizeof(*elf));
offset += sizeof(*elf); /* Elf header */
offset += (segs+1) * sizeof(struct elf_phdr); /* Program headers */
offset += (segs + 1) * sizeof(struct elf_phdr); /* Program headers */
foffset = offset;

/* Write notes phdr entry */
{
Expand All @@ -1586,8 +1587,6 @@ static int elf_core_dump(long signr, struct pt_regs *regs, struct file *file)
DUMP_WRITE(&phdr, sizeof(phdr));
}

foffset = offset;

dataoff = offset = roundup(offset, ELF_EXEC_PAGESIZE);

/* Write program headers for segments dump */
Expand All @@ -1612,7 +1611,6 @@ static int elf_core_dump(long signr, struct pt_regs *regs, struct file *file)
phdr.p_align = ELF_EXEC_PAGESIZE;

DUMP_WRITE(&phdr, sizeof(phdr));
foffset += sizeof(phdr);
}

#ifdef ELF_CORE_WRITE_EXTRA_PHDRS
Expand Down

0 comments on commit 977b1eb

Please sign in to comment.