diff options
author | Martin Pieuchot <mpi@cvs.openbsd.org> | 2017-08-10 19:39:39 +0000 |
---|---|---|
committer | Martin Pieuchot <mpi@cvs.openbsd.org> | 2017-08-10 19:39:39 +0000 |
commit | c5b1161eac7a9e74a903806fba19f36288845966 (patch) | |
tree | 6334a2f6bc3483792fc83ed111dca25acb2db2fc /sys/ddb/db_elf.c | |
parent | e55a17530b2fdc822fc5210e1c6702ed306d77b0 (diff) |
With a CTF kernel, DDB's print command will now pretty-print symbols.
Casting a type is not yet supported.
ok kettenis@, jasper@
Diffstat (limited to 'sys/ddb/db_elf.c')
-rw-r--r-- | sys/ddb/db_elf.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/ddb/db_elf.c b/sys/ddb/db_elf.c index fe4872e9a25..dbf41c127af 100644 --- a/sys/ddb/db_elf.c +++ b/sys/ddb/db_elf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_elf.c,v 1.26 2017/05/30 15:39:05 mpi Exp $ */ +/* $OpenBSD: db_elf.c,v 1.27 2017/08/10 19:39:38 mpi Exp $ */ /* $NetBSD: db_elf.c,v 1.13 2000/07/07 21:55:18 jhawk Exp $ */ /*- @@ -431,14 +431,14 @@ db_elf_sym_forall(db_forall_func_t db_forall_func, void *arg) } } -int -db_value_of_name(char *name, db_expr_t *valuep) +Elf_Sym * +db_symbol_by_name(char *name, db_expr_t *valuep) { Elf_Sym *sym; sym = db_elf_sym_lookup(name); if (sym == NULL) - return (0); + return (NULL); db_symbol_values(sym, &name, valuep); - return (1); + return (sym); } |