Merge pull request #289 from hpc/fix-ior-no-warn
IOR add warning if file exists #273. To stop on warnings, use existing flag --warningAsErrorsmaster
commit
09d2c3511b
11
src/ior.c
11
src/ior.c
|
@ -1293,6 +1293,17 @@ static void TestIoSys(IOR_test_t *test)
|
||||||
|
|
||||||
/* loop over test iterations */
|
/* loop over test iterations */
|
||||||
uint64_t params_saved_wearout = params->stoneWallingWearOutIterations;
|
uint64_t params_saved_wearout = params->stoneWallingWearOutIterations;
|
||||||
|
|
||||||
|
/* Check if the file exists and warn users */
|
||||||
|
if( params->hints.filePerProc || rank == 0){
|
||||||
|
struct stat sb;
|
||||||
|
GetTestFileName(testFileName, params);
|
||||||
|
int ret = backend->stat(testFileName, & sb, params->backend_options);
|
||||||
|
if(ret == 0) {
|
||||||
|
EWARNF("The file \"%s\" exists already and will be overwritten", testFileName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
for (rep = 0; rep < params->repetitions; rep++) {
|
for (rep = 0; rep < params->repetitions; rep++) {
|
||||||
/* Get iteration start time in seconds in task 0 and broadcast to
|
/* Get iteration start time in seconds in task 0 and broadcast to
|
||||||
all tasks */
|
all tasks */
|
||||||
|
|
Loading…
Reference in New Issue