diff options
author | H. Peter Anvin <hpa@zytor.com> | 2011-06-27 19:06:43 -0700 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2012-05-18 16:04:00 -0700 |
commit | 06531db8ec5d58477d7083d3d8130e909206233f (patch) | |
tree | 864b5572c8cab87184fe9a93e6f17b35ff3b5c35 /com32/lib/syslinux/movebits.c | |
parent | be697f88819ef20d72d1e7ea7d3d975d1fed5fb0 (diff) | |
download | syslinux-06531db8ec5d58477d7083d3d8130e909206233f.tar.gz |
com32: make syslinux_dump_*() pure debugging functions
Make the syslinux_dump_*() functions pure debugging functions; that is
the way that they are used anyway, and this way they log to the same
place as dprintf.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'com32/lib/syslinux/movebits.c')
-rw-r--r-- | com32/lib/syslinux/movebits.c | 26 |
1 files changed, 10 insertions, 16 deletions
diff --git a/com32/lib/syslinux/movebits.c b/com32/lib/syslinux/movebits.c index 6c75105a..7a05f3c1 100644 --- a/com32/lib/syslinux/movebits.c +++ b/com32/lib/syslinux/movebits.c @@ -228,10 +228,8 @@ static void shuffle_dealias(struct syslinux_movelist **fraglist, addr_t ps, pe, xs, xe, delta; bool advance; -#if DEBUG dprintf("Before alias resolution:\n"); - syslinux_dump_movelist(stdout, *fraglist); -#endif + syslinux_dump_movelist(*fraglist); *postcopy = NULL; @@ -302,12 +300,10 @@ restart: ; } -#if DEBUG dprintf("After alias resolution:\n"); - syslinux_dump_movelist(stdout, *fraglist); + syslinux_dump_movelist(*fraglist); dprintf("Post-shuffle copies:\n"); - syslinux_dump_movelist(stdout, *postcopy); -#endif + syslinux_dump_movelist(*postcopy); } /* @@ -435,12 +431,10 @@ nomem: /* As long as there are unprocessed fragments in the chain... */ while ((fp = &frags, f = *fp)) { -#if DEBUG dprintf("Current free list:\n"); - syslinux_dump_memmap(stdout, mmap); + syslinux_dump_memmap(mmap); dprintf("Current frag list:\n"); - syslinux_dump_movelist(stdout, frags); -#endif + syslinux_dump_movelist(frags); /* Scan for fragments which can be discarded without action. */ if (f->src == f->dst) { @@ -678,16 +672,16 @@ int main(int argc, char *argv[]) *fep = NULL; - printf("Input move list:\n"); - syslinux_dump_movelist(stdout, frags); - printf("Input free list:\n"); - syslinux_dump_memmap(stdout, memmap); + dprintf("Input move list:\n"); + syslinux_dump_movelist(frags); + dprintf("Input free list:\n"); + syslinux_dump_memmap(memmap); if (syslinux_compute_movelist(&moves, frags, memmap)) { printf("Failed to compute a move sequence\n"); return 1; } else { - printf("Final move list:\n"); + dprintf("Final move list:\n"); syslinux_dump_movelist(stdout, moves); return 0; } |