test/lvol: unlink aio files at start of test
This automatically cleans up aio files left over from earlier aborted runs. This helps streamline development of new tests and should have no impact on CI. Signed-off-by: Mike Gerdts <mgerdts@nvidia.com> Change-Id: Id65f60cdfc9969fda1dcdd17e60643ad87f45de7 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/17898 Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
3f57c5e317
commit
ee5ea993a0
@ -49,6 +49,7 @@ make_test_file(size_t size, char *path, size_t len, const char *name)
|
||||
if (snprintf(path, len, "%s/%s", g_testdir, name) >= (int)len) {
|
||||
return -ENAMETOOLONG;
|
||||
}
|
||||
unlink(path);
|
||||
fd = open(path, O_RDWR | O_CREAT | O_EXCL, 0600);
|
||||
if (fd < 0) {
|
||||
return -errno;
|
||||
|
Loading…
Reference in New Issue
Block a user