Skip to content

Commit

Permalink
hdzero: check size
Browse files Browse the repository at this point in the history
  • Loading branch information
bkleiner committed Sep 24, 2023
1 parent 95ea509 commit 1ce807d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/driver/serial_hdzero.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ static void hdzero_msp_send(msp_magic_t magic, uint8_t direction, uint16_t cmd,
buf[size++] = crc8_dvb_s2_data(crc, data, len);

serial_write_bytes(&serial_hdzero, buf, size);
} else {
} else if (len < 255) {
if (serial_bytes_free(&serial_hdzero) < (len + MSP_HEADER_LEN + 1)) {
return;
}
Expand Down

0 comments on commit 1ce807d

Please sign in to comment.