From 51172783e2211bc90017d14bafec5d2eb4080694 Mon Sep 17 00:00:00 2001 From: Michael Brown Date: Sun, 12 Jul 2009 21:30:08 +0100 Subject: [debug] Use a delimiter to break up DBG_HD() output Reading sixteen columns of hex digits can be difficult; include a "-" character to split the output into two groups of eight columns. --- src/core/debug.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/debug.c b/src/core/debug.c index 500a7ac0..8f929309 100644 --- a/src/core/debug.c +++ b/src/core/debug.c @@ -36,7 +36,8 @@ static void dbg_hex_dump_da_row ( unsigned long dispaddr, const void *data, printf ( " " ); continue; } - printf ( " %02x", bytes[i] ); + printf ( "%c%02x", + ( ( ( i % 16 ) == 8 ) ? '-' : ' ' ), bytes[i] ); } printf ( " : " ); for ( i = offset ; i < ( offset + 16 ) ; i++ ) { -- cgit v1.2.3-55-g7522