aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Schneider <asn@cryptomilk.org>2019-06-13 16:38:54 +0200
committerAndreas Schneider <asn@cryptomilk.org>2019-06-13 16:43:44 +0200
commit1f43b52117fc97eef95e3627517cadb531b2b43e (patch)
tree7ee2048a93883ad438422c7e7c0b2329e7ee091e
parentc0c1454298aafefa9912e4cdd89b32f4c4eb9b6f (diff)
downloadlibssh-1f43b52117fc97eef95e3627517cadb531b2b43e.tar.gz
libssh-1f43b52117fc97eef95e3627517cadb531b2b43e.tar.xz
libssh-1f43b52117fc97eef95e3627517cadb531b2b43e.zip
tests: Fix the glob test on musl libc
Fixes #150 Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
-rw-r--r--tests/unittests/torture_config.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/unittests/torture_config.c b/tests/unittests/torture_config.c
index 95f135e7..f5bf37d0 100644
--- a/tests/unittests/torture_config.c
+++ b/tests/unittests/torture_config.c
@@ -300,16 +300,16 @@ static void torture_config_double_ports(void **state) {
static void torture_config_glob(void **state) {
ssh_session session = *state;
int ret;
-#ifdef HAVE_GLOB
+#if defined(HAVE_GLOB) && defined(HAVE_GLOB_GL_FLAGS_MEMBER)
char *v;
-#endif
+#endif /* HAVE_GLOB && HAVE_GLOB_GL_FLAGS_MEMBER */
ret = ssh_config_parse_file(session, LIBSSH_TESTCONFIG5);
assert_true(ret == 0); /* non-existing files should not error */
/* Test the variable presence */
-#ifdef HAVE_GLOB
+#if defined(HAVE_GLOB) && defined(HAVE_GLOB_GL_FLAGS_MEMBER)
ret = ssh_options_get(session, SSH_OPTIONS_PROXYCOMMAND, &v);
assert_true(ret == 0);
assert_non_null(v);
@@ -323,7 +323,7 @@ static void torture_config_glob(void **state) {
assert_string_equal(v, ID_FILE);
SSH_STRING_FREE_CHAR(v);
-#endif /* HAVE_GLOB */
+#endif /* HAVE_GLOB && HAVE_GLOB_GL_FLAGS_MEMBER */
}
/**