aboutsummaryrefslogtreecommitdiff
path: root/a8xd.c
diff options
context:
space:
mode:
authorB. Watson <urchlay@slackware.uk>2024-06-30 05:15:01 -0400
committerB. Watson <urchlay@slackware.uk>2024-06-30 05:25:05 -0400
commit23f9f330695ece85322909f302080085a681bed4 (patch)
tree98edd58c884bca8e3013c9626ef24b0613d69bc3 /a8xd.c
parentbeaa4db4b09bedde5ff8c72bd0ac3944c6483e98 (diff)
downloadbw-atari8-tools-23f9f330695ece85322909f302080085a681bed4.tar.gz
a8xd: print correct hex value in -a mode.
Diffstat (limited to 'a8xd.c')
-rw-r--r--a8xd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/a8xd.c b/a8xd.c
index 534267c..f887d05 100644
--- a/a8xd.c
+++ b/a8xd.c
@@ -244,12 +244,12 @@ void dump_line(const unsigned char *buf, int len) {
while(len) {
c = *buf;
- if(screencodes) c = screen2ata(c);
inv = !graphics && (c & 0x80);
+ if(screencodes) c = screen2ata(c);
if(color) hpos += sprintf(hex + hpos, "%s", get_color(c));
if(inv) hpos += sprintf(hex + hpos, "%s", inverse_on);
- hpos += sprintf(hex + hpos, byte_format, c);
+ hpos += sprintf(hex + hpos, byte_format, *buf); /* *buf here, not c! */
if(color || inv) hpos += sprintf(hex + hpos, "%s", color_off);
hex[hpos++] = ' ';
if(count - len == 7) hex[hpos++] = ' ';