1
0
mirror of https://git.libssh.org/projects/libssh.git synced 2025-08-01 11:26:52 +03:00

tests: Fix the glob test on musl libc

Fixes #150

Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
Andreas Schneider
2019-06-13 16:38:54 +02:00
parent c0c1454298
commit 1f43b52117

View File

@ -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 */
}
/**