aboutsummaryrefslogtreecommitdiff
path: root/sys/ddb/db_examine.c
diff options
context:
space:
mode:
authorPoul-Henning Kamp <phk@FreeBSD.org>1996-01-15 22:41:03 +0000
committerPoul-Henning Kamp <phk@FreeBSD.org>1996-01-15 22:41:03 +0000
commit791d77e0ddbf1ac83525783d454f61330c9053ba (patch)
tree211438af77a23891624f21f01f20a5620899f56d /sys/ddb/db_examine.c
parent3eb50b2eddeda38038d81e2786dc1f1fe0c89ec5 (diff)
downloadsrc-791d77e0ddbf1ac83525783d454f61330c9053ba.tar.gz
src-791d77e0ddbf1ac83525783d454f61330c9053ba.zip
Get rid of two and a half printf in the kernel.
Add more features to the one remaining to handle the job: + signed quantity. # alternate format - left padding * read width as next arg. n numeric in (argument specified) default radix. Fix the DDB debugger to use these. Use vprintf in debug routine in pcvt. The warnings from gcc may become more wrong and intolerable because of this. Warning: I have not checked the entire source for unsupported or changed constructs, but generally belive that there are only a few. Suggested by: bde
Notes
Notes: svn path=/head/; revision=13446
Diffstat (limited to 'sys/ddb/db_examine.c')
-rw-r--r--sys/ddb/db_examine.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/ddb/db_examine.c b/sys/ddb/db_examine.c
index 9c8c21c4b02d..ce7cff602cf4 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.11 1995/12/07 12:44:49 davidg Exp $
+ * $Id: db_examine.c,v 1.12 1995/12/10 19:07:55 bde Exp $
*/
/*
@@ -127,7 +127,7 @@ db_examine(addr, fmt, count)
case 'z': /* signed hex */
value = db_get_value(addr, size, TRUE);
addr += size;
- db_printf("%-*z", width, value);
+ db_printf("%+-*x", width, value);
break;
case 'd': /* signed decimal */
value = db_get_value(addr, size, TRUE);
@@ -205,13 +205,13 @@ db_print_cmd(addr, have_addr, count, modif)
db_printsym((db_addr_t)addr, DB_STGY_ANY);
break;
case 'r':
- db_printf("%11r", addr);
+ db_printf("%+11n", addr);
break;
case 'x':
db_printf("%8x", addr);
break;
case 'z':
- db_printf("%8z", addr);
+ db_printf("%+8x", addr);
break;
case 'd':
db_printf("%11d", addr);