drivers/crypto/se05x: zero the size a failed read leaves

pnt_se05x_get_data() compared the object size with the buffer even when ReadSize had failed and left it unset.

Signed-off-by: Royyan Zahir <royzah@gmail.com>
This commit is contained in:
Royyan Zahir 2026-10-04 08:25:02 +04:00 • committed by GUIDINGLI
parent 324a0cd437
commit 6b4e6a0335

View file

@ -247,7 +247,7 @@ int pnt_se05x_get_key(FAR struct se05x_dev_s *se05x,
int pnt_se05x_get_data(FAR struct se05x_dev_s *se05x,
FAR struct se05x_key_transmission_s *get_key_args)
{
uint16_t remainder;
uint16_t remainder = 0;
smStatus_t status = Se05x_API_ReadSize(&(se05x->pnt->session),
get_key_args->entry.id, &remainder);