Unverified Commit 36f8cb24 authored by George Oikonomou's avatar George Oikonomou Committed by GitHub
Browse files

Merge pull request #294 from g-oikonomou/bugfix/ieee-mode-frame-length

Correctly check against minumum RX frame length
parents 9e15ace3 5f6eee66
......@@ -1079,17 +1079,17 @@ read_frame(void *buf, unsigned short buf_len)
return 0;
}
if(rx_read_entry[8] < 4) {
PRINTF("RF: too short\n");
len = rx_read_entry[8] - 8;
if(len > buf_len) {
PRINTF("RF: too long\n");
release_data_entry();
return 0;
}
len = rx_read_entry[8] - 8;
if(len > buf_len) {
PRINTF("RF: too long\n");
if(len < 5) {
PRINTF("RF: too short\n");
release_data_entry();
return 0;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment