From 51d1a0c22d3c9f28786e87ffd09bc5f379df6cc4 Mon Sep 17 00:00:00 2001 From: bde Date: Wed, 8 Jul 1998 06:27:22 +0000 Subject: Fixed db_printf format errors (except for ones using broken extensions (nonstandard %n and '+' with %x), and ones not found by -Wformat on 386's (some db_expr_t's are still printed as ints). I decided not to change the arg type for %n from [unsigned] int to register_t, since about half of the uses of %n are to print plain ints and casting to [unsigned] long for %n is no harder than for %x. --- sys/ddb/db_examine.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'sys/ddb') diff --git a/sys/ddb/db_examine.c b/sys/ddb/db_examine.c index fbd402b..9dd9d09 100644 --- a/sys/ddb/db_examine.c +++ b/sys/ddb/db_examine.c @@ -23,7 +23,7 @@ * any improvements or extensions that they make and grant Carnegie the * rights to redistribute these changes. * - * $Id: db_examine.c,v 1.21 1998/06/27 15:39:51 dfr Exp $ + * $Id: db_examine.c,v 1.22 1998/07/05 10:10:33 dfr Exp $ */ /* @@ -208,22 +208,22 @@ db_print_cmd(addr, have_addr, count, modif) db_printsym((db_addr_t)addr, DB_STGY_ANY); break; case 'r': - db_printf("%+11ln", addr); + db_printf("%+11ln", (long)addr); break; case 'x': - db_printf("%8lx", addr); + db_printf("%8lx", (unsigned long)addr); break; case 'z': - db_printf("%+8lx", addr); + db_printf("%+8lx", (long)addr); break; case 'd': - db_printf("%11ld", addr); + db_printf("%11ld", (long)addr); break; case 'u': - db_printf("%11lu", addr); + db_printf("%11lu", (unsigned long)addr); break; case 'o': - db_printf("%16lo", addr); + db_printf("%16lo", (unsigned long)addr); break; case 'c': value = addr & 0xFF; -- cgit v1.1