tests: Fix off-by-one error in array bounds check
tests: Fix off-by-one error in array bounds check

rptr points to an object with rsize number of bytes. If offset + size ==
rsize, then rptr + offset + size will point to one byte past the end of
the object during the memcpy(). Exclude this case by adding it to the
bounds check. We can also remove the offset > rsize check since it is
subsumed in the other one.

BUG=none
TEST=make clean && make runtests
BRANCH=none

Change-Id: Iceda658f420babe61bd1d9807efc8333d2044ccc
Signed-off-by: Jacob Garber <1cfd0af4873bfe82c672d82b221bc685f9ea5148@ualberta.ca>
Found-by: Coverity CID 198905
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vboot_reference/+/1752766
Reviewed-by: Joel Kitching <c2feea8c1334a0d339e816ae4c7c9ecfa9b30a91@chromium.org>

coreboot/vboot,coreboot/vboot,coreboot/vboot,coreboot/vboot,coreboot/vboot