From d8cba19f2ac596932744796c49a7088dd5f20fb7 Mon Sep 17 00:00:00 2001 From: adilger Date: Wed, 14 Dec 2005 01:02:23 +0000 Subject: [PATCH] Branch b_release_1_4_6 Allow test to run with existing dir. b=9692 --- lustre/liblustre/tests/sanity.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lustre/liblustre/tests/sanity.c b/lustre/liblustre/tests/sanity.c index bf0021d..13be9d3 100644 --- a/lustre/liblustre/tests/sanity.c +++ b/lustre/liblustre/tests/sanity.c @@ -365,7 +365,11 @@ int t14(char *name) ENTRY(">1 block(4k) directory readdir"); snprintf(dir, MAX_PATH_LENGTH, "%s/test_t14_dir/", lustre_path); - t_mkdir(dir); + rc = mkdir(dir, 0755); + if (rc < 0 && errno != ENOENT) { + printf("mkdir(%s) error: %s\n", dir, strerror(errno)); + exit(1); + } printf("Creating %d files...\n", nfiles); for (i = 0; i < nfiles; i++) { sprintf(path, "%s%s%05d", dir, prefix, i); -- 1.8.3.1