mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2025-12-12 20:49:49 +04:00
add extra check
This commit is contained in:
@@ -379,6 +379,9 @@ SubGhzProtocolStatus
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(instance->generic.data_count_bit != 64) {
|
if(instance->generic.data_count_bit != 64) {
|
||||||
|
if(instance->generic.data_count_bit < 62) {
|
||||||
|
return SubGhzProtocolStatusErrorValueBitCount;
|
||||||
|
}
|
||||||
// Removing possible artifacts from higher bits and setting header to FF FE
|
// Removing possible artifacts from higher bits and setting header to FF FE
|
||||||
instance->generic.data =
|
instance->generic.data =
|
||||||
((((((0xFF << 16) | ((instance->generic.data >> 40) & 0xFFFF)) << 16) |
|
((((((0xFF << 16) | ((instance->generic.data >> 40) & 0xFFFF)) << 16) |
|
||||||
|
|||||||
Reference in New Issue
Block a user