summaryrefslogtreecommitdiffstats
path: root/src/strip.c
diff options
context:
space:
mode:
authorUlrich Drepper <[email protected]>2009-06-13 15:55:42 -0700
committerUlrich Drepper <[email protected]>2009-06-13 15:55:42 -0700
commitf189493154d0041deced00e6a99cc5426dc9d260 (patch)
tree6c55e4b0b571c49d01e1b355e52f72b6d5c069eb /src/strip.c
parentb47d290a36509e26e145f6d3eb2e6590ec6c554d (diff)
Add aliases for elf_getshnum and elf_getshstrndx.
Sun in their implementation messed up the semantics of these functions. To get back to source code compatibility they asked for a solution. We simply add aliases for the two affected functions, named elf_getshdrnum and elf_getshdrstrndx. The semantics remains the same. Users of the old interfaces receive a warning for now. In future we might make it impossible to link programs which request the old interfaces (binary compatibility will of course be maintained).
Diffstat (limited to 'src/strip.c')
-rw-r--r--src/strip.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/strip.c b/src/strip.c
index d788ebf2..32cf0d70 100644
--- a/src/strip.c
+++ b/src/strip.c
@@ -477,7 +477,7 @@ handle_elf (int fd, Elf *elf, const char *prefix, const char *fname,
INTERNAL_ERROR (fname);
/* Get the section header string table index. */
- if (unlikely (elf_getshstrndx (elf, &shstrndx) < 0))
+ if (unlikely (elf_getshdrstrndx (elf, &shstrndx) < 0))
error (EXIT_FAILURE, 0,
gettext ("cannot get section header string table index"));
@@ -537,7 +537,7 @@ handle_elf (int fd, Elf *elf, const char *prefix, const char *fname,
/* Number of sections. */
size_t shnum;
- if (unlikely (elf_getshnum (elf, &shnum) < 0))
+ if (unlikely (elf_getshdrnum (elf, &shnum) < 0))
{
error (0, 0, gettext ("cannot determine number of sections: %s"),
elf_errmsg (-1));