From b640948bc1831dd72b6575d0037046924a4f7de6 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Thu, 1 Jan 2009 15:24:37 +0100 Subject: tibtoa: Print offset for unknown bytes --- bin/tibtoa | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'bin') diff --git a/bin/tibtoa b/bin/tibtoa index 7ad8833..a9cd03a 100755 --- a/bin/tibtoa +++ b/bin/tibtoa @@ -635,7 +635,11 @@ while($offset <= $length) { $char2 = ord(substr($program, $offset++, 1)); $out = $special->{$char}->{$char2}; } else { - warn(sprintf('Unknown byte 0x%02x', $char)); + printf STDERR ( + "Unknown byte 0x%02x at offset %d\n", + $char, + $offset - 1, + ); $out = chr($char); } if ($opts{i}) { -- cgit v1.2.3