summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorDaniel Friesel <derf@derf.homelinux.org>2009-01-01 15:24:37 +0100
committerDaniel Friesel <derf@derf.homelinux.org>2009-01-01 15:24:37 +0100
commitb640948bc1831dd72b6575d0037046924a4f7de6 (patch)
tree7c925e86390b2122ffa3e31e77ee214531127a32 /bin
parent347b60b62be557c42e5c0bbc92dbb8561a931178 (diff)
tibtoa: Print offset for unknown bytes
Diffstat (limited to 'bin')
-rwxr-xr-xbin/tibtoa6
1 files changed, 5 insertions, 1 deletions
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}) {