summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhpa <hpa>1999-03-05 15:08:35 +0000
committerhpa <hpa>1999-03-05 15:08:35 +0000
commit3aeb29356b1d04adbcb9f01be35923d17a46a6c7 (patch)
tree4151dd8a7f80865f48ee43ded36570bfd69ef8e5
parent944454360874dc411891225c40d1bef206f43fc8 (diff)
downloadsyslinux-3aeb29356b1d04adbcb9f01be35923d17a46a6c7.tar.gz
Bug fixes.
-rwxr-xr-xsys2ansi.pl7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys2ansi.pl b/sys2ansi.pl
index bcd07cca..5a0c1ca9 100755
--- a/sys2ansi.pl
+++ b/sys2ansi.pl
@@ -1,13 +1,16 @@
#!/usr/bin/perl
+# $Id$
#
# Perl script to convert a Syslinux-format screen to PC-ANSI
#
@ansicol = (0,4,2,6,1,5,3,7);
while ( read(STDIN, $ch, 1) > 0 ) {
- if ( $ch == '\x1A' ) { # <SUB> <Ctrl-Z> EOF
+ if ( $ch eq "\x1A" ) { # <SUB> <Ctrl-Z> EOF
last;
- } elsif ( $ch == '\x13' ) { # <SI> <Ctrl-O> Attribute change
+ } elsif ( $ch eq "\x0C" ) { # <FF> <Ctrl-L> Clear screen
+ print "\x1b[2J";
+ } elsif ( $ch eq "\x0F" ) { # <SI> <Ctrl-O> Attribute change
if ( read(STDIN, $attr, 2) == 2 ) {
$attr = hex $attr;
print "\x1b[0;";