return back after merge

This commit is contained in:
MX 2024-09-05 22:14:40 +03:00
parent 56530ee61c
commit 2683f950a7
No known key found for this signature in database
GPG Key ID: 7CCC66B7DBDD1C83

View File

@ -59,7 +59,16 @@ bool subghz_file_encoder_worker_data_parse(SubGhzFileEncoderWorker* instance, co
// Parse next element // Parse next element
int32_t duration; int32_t duration;
while(strint_to_int32(str, &str, &duration, 10) == StrintParseNoError) { while(strint_to_int32(str, &str, &duration, 10) == StrintParseNoError) {
if((duration < -1000000) || (duration > 1000000)) {
if(duration > 0) {
subghz_file_encoder_worker_add_level_duration(instance, (int32_t)100);
} else {
subghz_file_encoder_worker_add_level_duration(instance, (int32_t)-100);
}
//FURI_LOG_I("PARSE", "Number overflow - %d", duration);
} else {
subghz_file_encoder_worker_add_level_duration(instance, duration); subghz_file_encoder_worker_add_level_duration(instance, duration);
}
if(*str == ',') str++; // could also be `\0` if(*str == ',') str++; // could also be `\0`
} }