tools: env: Handle shorter read calls
authorThibault Ferrante <thibaultferrante@gmail.com>
Tue, 24 Aug 2021 15:29:50 +0000 (17:29 +0200)
committerTom Rini <trini@konsulko.com>
Thu, 2 Sep 2021 15:19:58 +0000 (11:19 -0400)
commit6628813f9d400c49da4926f01833063a30151cdb
treec3f4646963db0c7010ca32b024b6947f4f144d9f
parent7befc8490a008c332633e693f2adfab38d8d50f2
tools: env: Handle shorter read calls

On some cases, the actual number of bytes read can be shorter
than what was requested. This can be handled gracefully by
taking this difference into account instead of exiting.

Signed-off-by: Thibault Ferrante <thibault.ferrante@gmail.com>
tools/env/fw_env.c