]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Miscellaneous ZTS fixes
authorRichard Yao <richard.yao@alumni.stonybrook.edu>
Thu, 29 Sep 2022 15:56:42 +0000 (11:56 -0400)
committerGitHub <noreply@github.com>
Thu, 29 Sep 2022 15:56:42 +0000 (08:56 -0700)
commit570ca4441e0583c8dcb5c7179f5eb331d1172784
tree01f230f676d89d145c7a68ad076b03cbe1a88155
parent55c12724d377e6c7ace5b4bd42cd728d4a60af3e
Miscellaneous ZTS fixes

Coverity had various complaints about minor issues. They are all fairly
straightforward to understand without reading additional files, with the
exception of the draid.c issue. vdev_draid_rand() takes a 128-bit
starting seed, but we were passing a pointer to a 64-bit value, which
understandably made Coverity complain. This is perhaps the only
significant issue fixed in this patch, since it causes stack corruption.

These are not all of the issues in the ZTS that Coverity caught, but a
number of them are already fixed in other PRs. There is also a class of
TOUTOC complaints that involve very minor things in the ZTS (e.g.
access() before unlink()). I have yet to decide whether they are false
positives (since this is not security sensitive code) or something to
cleanup.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Neal Gompa <ngompa@datto.com>
Signed-off-by: Richard Yao <richard.yao@alumni.stonybrook.edu>
Closes #13943
tests/zfs-tests/cmd/draid.c
tests/zfs-tests/cmd/file/file_trunc.c
tests/zfs-tests/cmd/file/randwritecomp.c
tests/zfs-tests/cmd/get_diff.c
tests/zfs-tests/cmd/libzfs_input_check.c
tests/zfs-tests/cmd/mmapwrite.c
tests/zfs-tests/cmd/readmmap.c
tests/zfs-tests/cmd/zed_fd_spill-zedlet.c