summaryrefslogtreecommitdiffstats
path: root/sys/ddb/db_main.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/ddb/db_main.c')
-rw-r--r--sys/ddb/db_main.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/ddb/db_main.c b/sys/ddb/db_main.c
index 32dd347..0a2cd56 100644
--- a/sys/ddb/db_main.c
+++ b/sys/ddb/db_main.c
@@ -170,9 +170,11 @@ db_init(void)
if (ksym_end > ksym_start && ksym_start != 0) {
symtab = ksym_start;
- tabsz = *((Elf_Size*)symtab)++;
+ tabsz = *((Elf_Size*)symtab);
+ tabsz += sizeof(Elf_Size);
strtab = symtab + tabsz;
- strsz = *((Elf_Size*)strtab)++;
+ strsz = *((Elf_Size*)strtab);
+ strsz += sizeof(Elf_Size);
if (strtab + strsz <= ksym_end) {
db_add_symbol_table((char *)symtab,
(char *)(symtab + tabsz), "elf", (char *)strtab);
OpenPOWER on IntegriCloud