aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2001-05-17 19:07:36 +0000
committerUlrich Drepper <drepper@redhat.com>2001-05-17 19:07:36 +0000
commit8d88a1640560d5b26c8119f7a763b4c0607eec56 (patch)
tree213fb181b0389d8e915d6a6e9b98b47c6f6436a3
parent8df6c274bccc0d0c982b301b22d3e180bdb0e5d2 (diff)
downloadglibc-8d88a1640560d5b26c8119f7a763b4c0607eec56.zip
glibc-8d88a1640560d5b26c8119f7a763b4c0607eec56.tar.gz
glibc-8d88a1640560d5b26c8119f7a763b4c0607eec56.tar.bz2
Update.
2001-05-17 H.J. Lu <hjl@gnu.org> * elf/sprof.c (read_symbols): Move "++symtab" into the while loop.
-rw-r--r--ChangeLog4
-rw-r--r--elf/sprof.c8
2 files changed, 8 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 4fec3ad..6fa95fa 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2001-05-17 H.J. Lu <hjl@gnu.org>
+
+ * elf/sprof.c (read_symbols): Move "++symtab" into the while loop.
+
2001-05-17 Ulrich Drepper <drepper@redhat.com>
* sysdeps/unix/sysv/linux/sigprocmask.c (__sigprocmask): Use
diff --git a/elf/sprof.c b/elf/sprof.c
index 2dccf8f..b66ed49 100644
--- a/elf/sprof.c
+++ b/elf/sprof.c
@@ -912,7 +912,7 @@ read_symbols (struct shobj *shobj)
obstack_init (&ob_list);
/* Process the symbols. */
- if (shobj->symtab)
+ if (shobj->symtab != NULL)
{
const ElfW(Sym) *sym = shobj->symtab;
const ElfW(Sym) *sym_end
@@ -965,7 +965,7 @@ read_symbols (struct shobj *shobj)
/* We assume that the string table follows the symbol table,
because there is no way in ELF to know the size of the
- dynamic symbol table!! */
+ dynamic symbol table without looking at the section headers. */
while ((void *) symtab < (void *) strtab)
{
if ((ELFW(ST_TYPE)(symtab->st_info) == STT_FUNC
@@ -1006,9 +1006,9 @@ read_symbols (struct shobj *shobj)
obstack_free (&shobj->ob_sym, newsym);
}
}
- }
- ++symtab;
+ ++symtab;
+ }
}
sortsym = malloc (n * sizeof (struct known_symbol *));