diff --git a/tests/libtest/lib1536.c b/tests/libtest/lib1536.c index 7a1aa9bfa..6fe3bc787 100644 --- a/tests/libtest/lib1536.c +++ b/tests/libtest/lib1536.c @@ -69,7 +69,7 @@ int test(char *URL) __FILE__, __LINE__, res, curl_easy_strerror(res)); goto test_cleanup; } - if(memcmp(scheme, "HTTP", 5) != 0) { + if(scheme == NULL || memcmp(scheme, "HTTP", 5) != 0) { fprintf(stderr, "%s:%d scheme of http resource is incorrect; " "expected 'HTTP' but is %s\n", __FILE__, __LINE__,