From 8ed2f6b8bf6465197230b196f013b9cae1308ca8 Mon Sep 17 00:00:00 2001 From: Artem Bityutskiy Date: Thu, 26 May 2011 16:04:20 +0300 Subject: fs-tests: integck: add some more error messages Signed-off-by: Artem Bityutskiy --- tests/fs-tests/integrity/integck.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'tests/fs-tests') diff --git a/tests/fs-tests/integrity/integck.c b/tests/fs-tests/integrity/integck.c index e2a878f..54e5ddc 100644 --- a/tests/fs-tests/integrity/integck.c +++ b/tests/fs-tests/integrity/integck.c @@ -1562,7 +1562,10 @@ static void file_check(struct file_info *file, int fd) path = dir_path(file->links->parent, get_file_name(file)); v("checking file %s", path); fd = open(path, O_RDONLY); - CHECK(fd != -1); + if (fd == -1) { + sys_errmsg("cannot open file %s", path); + CHECK(0); + } } else v("checking file %s", get_file_name(file)); @@ -1722,7 +1725,7 @@ static void dir_check(struct dir_info *dir) /* Go through directory on file system checking entries match */ d = opendir(path); if (!d) { - errmsg("cannot open directory %s", path); + sys_errmsg("cannot open directory %s", path); CHECK(0); } -- cgit v1.2.3