Handle more invalid characters in SPD model field if encountered

This commit is contained in:
Jarrod Johnson 2014-09-09 13:41:19 -04:00
parent 532c7d618c
commit 541dcf53d3

View File

@ -815,7 +815,7 @@ sub decode_spd {
$rethash->{product}->{builddate} = sprintf("Week %x of 20%02x",$spd[323],$spd[324]);
}
foreach (@spd[329..348]) {
if ($_ & 0b10000000) {
if ($_ > 126 or $_ < 32) {
$rethash->{product}->{model}="Malformed SPD";
}
}