projects
/
platform
/
upstream
/
syslinux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
19edf5c
)
Ignore carriage return characters -- same behaviour as syslinux
author
hpa
<hpa>
Wed, 28 Mar 2001 21:48:30 +0000
(21:48 +0000)
committer
hpa
<hpa>
Wed, 28 Mar 2001 21:48:30 +0000
(21:48 +0000)
sys2ansi.pl
patch
|
blob
|
history
diff --git
a/sys2ansi.pl
b/sys2ansi.pl
index
bd7fd5a
..
d4b47db
100755
(executable)
--- a/
sys2ansi.pl
+++ b/
sys2ansi.pl
@@
-2,6
+2,7
@@
# $Id$
#
# Perl script to convert a Syslinux-format screen to PC-ANSI
+# to display in a color xterm or on the Linux console
#
@ansicol = (0,4,2,6,1,5,3,7);
@@
-25,8
+26,9
@@
while ( read(STDIN, $ch, 1) > 0 ) {
printf "%d;%dm",
$ansicol[$attr >> 4] + 40, $ansicol[$attr & 7] + 30;
}
+ } elsif ( $ch eq "\x0D" ) { # <CR> <Ctrl-M> Carriage return
+ # Ignore
} else {
print $ch;
}
}
-