Skip to content
Snippets Groups Projects
Commit 34a60d9b authored by Stephen Warren's avatar Stephen Warren Committed by Tom Rini
Browse files

test: fat: add error-checking to non-contig test


Check the result code of all command that are executed. Without this,
if the fallocate invocation fails (this feature is not supported on ext3
filesystems for example) then a zero-length output file will be created,
and subsequent the mkfs and mount invocations will fail, which will cause
the subsequent dd invocation to attempt to fill up the host's entire free
disk space. That's not a nice user experience!

Related, if fallocate does fail, try to create the test disk image using
dd instead. That should work everywhere.

Fixes: 4a282742 ("test: fat: add test of non-contiguous file reads")
Signed-off-by: default avatarStephen Warren <swarren@nvidia.com>
parent 60f989a9
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment