diff options
| author | Ulrich Drepper <[email protected]> | 2009-01-26 09:20:36 -0800 |
|---|---|---|
| committer | Ulrich Drepper <[email protected]> | 2009-01-26 09:20:36 -0800 |
| commit | 119f4acbaec5b538a4206fd261067137d3588f55 (patch) | |
| tree | eff50ddcadd3e2a727820220e980f2b48c655ae3 | |
| parent | 11ed669865964b0ea98954c15557d99c0c55364e (diff) | |
Fix commit in updatenull_wrlock wrt to layout resulting from section header
table position and size.
| -rw-r--r-- | libelf/ChangeLog | 5 | ||||
| -rw-r--r-- | libelf/elf32_updatenull.c | 7 |
2 files changed, 9 insertions, 3 deletions
diff --git a/libelf/ChangeLog b/libelf/ChangeLog index 119fa5b1..87c24e4f 100644 --- a/libelf/ChangeLog +++ b/libelf/ChangeLog @@ -1,3 +1,8 @@ +2009-01-26 Ulrich Drepper <[email protected]> + + * elf32_updatenull.c (updatenull_wrlock): Fix comment of + ELF_F_LAYOUT behaviour re section header table. + 2009-01-22 Ulrich Drepper <[email protected]> * elf32_updatefile.c (__elfXX_updatemmap): Fill the gap between diff --git a/libelf/elf32_updatenull.c b/libelf/elf32_updatenull.c index a18d0bea..5ce8bbc9 100644 --- a/libelf/elf32_updatenull.c +++ b/libelf/elf32_updatenull.c @@ -1,5 +1,5 @@ /* Update data structures for changes. - Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006 Red Hat, Inc. + Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 Red Hat, Inc. This file is part of Red Hat elfutils. Written by Ulrich Drepper <[email protected]>, 2000. @@ -401,8 +401,9 @@ __elfw2(LIBELFBITS,updatenull_wrlock) (Elf *elf, int *change_bop, size_t shnum) /* Store section information. */ if (elf->flags & ELF_F_LAYOUT) { - /* The user is supposed to fill out e_phoff. Use it and - e_phnum to determine the maximum extend. */ + /* The user is supposed to fill out e_shoff. Use it and + e_shnum (or sh_size of the dummy, first section header) + to determine the maximum extend. */ size = MAX ((GElf_Word) size, (ehdr->e_shoff + (elf_typesize (LIBELFBITS, ELF_T_SHDR, shnum)))); |
