memcmp: fix comparison on short read
read() might return less than $count bytes which is only an upper limit.
The user is supposed to repeat the command to fill a buffer completely.

So use the convenience wrapper read_full in memcmp.

This fixes memcmp on /dev/nand0 on an Armada XP.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent 019606d commit e0ff988ad865f3370ddeb8e75eefd9ed27d6641b
@Uwe Kleine-König Uwe Kleine-König authored on 1 Mar 2017
Sascha Hauer committed on 2 Mar 2017
Showing 1 changed file
View
commands/memcmp.c