use feature "switch";
use Time::HiRes qw( time usleep );
use CGI::Carp qw(fatalsToBrowser);
+use HTML::Entities qw(encode_entities);
use if (!defined $ENV{'QUERY_STRING'}), warnings;
use if (!defined $ENV{'QUERY_STRING'}), Pod::Usage;
}
my $range = $obj->{start}+$obj->{bits}-1;
$range .= "..".$obj->{start} if ($obj->{bits}>1);
- $ret .= " ".$obj->{unit} if exists $obj->{unit};
+ $ret .= " ".encode_entities($obj->{unit}) if exists $obj->{unit};
$ret .= sprintf("<span class=\"tooltip\"><b>$name</b> (Bit $range)<br>raw: 0x%x<br>$cstr</span></div>",$rawvalue);
}
}
default {$ret = sprintf("0x%08x",$value);}
}
- $ret .= " ".$obj->{unit} if exists $obj->{unit};
+ $ret .= " ".encode_entities($obj->{unit}) if exists $obj->{unit};
}
return $ret;
}