Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
syscalls/msgstress01: Fix off by one in array access
The size returned from recvmsg() is the size of the payload but the payload is defined as: struct { char len; char pbytes[99]; } data; So the lenght of the pbytes is actually one byte shorter than the size and we access one byte after the array in the comparsion. Better fix for this would be removal of the len from the data payload but since we are close to the release lets do the minimal fix now and do the cleanup after the release. Link: https://lore.kernel.org/ltp/[email protected]/ Reviewed-by: Petr Vorel <[email protected]> Signed-off-by: Cyril Hrubis <[email protected]>
- Loading branch information