Exit eoe receive function if buffer is not valid

If buffer is invalid the call to the subsequent memcpy will corrupt memory
pull/134/head
m-dema 2022-09-23 17:04:42 +02:00 committed by GitHub
parent 8de160a851
commit 66b040a257
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 0 deletions

View File

@ -763,6 +763,12 @@ static void EOE_receive_fragment (void)
EOEvar.rxframeoffset = 0;
EOEvar.rxframeno = EOE_HDR_FRAME_NO_GET(frameinfo2);
}
else
{
DPRINT("Receive buffer is invalid\n");
EOE_init_rx ();
return;
}
}
/* In frame fragment received */
else