aboutsummaryrefslogtreecommitdiff
path: root/tests/torture.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/torture.c')
-rw-r--r--tests/torture.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/torture.c b/tests/torture.c
index 7456cb60..983f1c38 100644
--- a/tests/torture.c
+++ b/tests/torture.c
@@ -128,6 +128,16 @@ int torture_rmdirs(const char *path) {
return 0;
}
+int torture_isdir(const char *path) {
+ struct stat sb;
+
+ if (lstat (path, &sb) == 0 && S_ISDIR(sb.st_mode)) {
+ return 1;
+ }
+
+ return 0;
+}
+
int torture_libssh_verbosity(void){
return verbosity;
}