1
0
mirror of https://github.com/moparisthebest/curl synced 2024-08-13 17:03:50 -04:00

tests: fix build with CURL_DISABLE_DOH

Closes https://github.com/curl/curl/pull/4692
This commit is contained in:
Marcel Raad 2019-12-09 11:42:26 +01:00
parent ec3758b95f
commit 9f239811fd
No known key found for this signature in database
GPG Key ID: 33C416EFAE4D6F02
2 changed files with 14 additions and 2 deletions

View File

@ -33,7 +33,7 @@ static void unit_stop(void)
}
#ifdef USE_NGHTTP2
#ifndef CURL_DISABLE_DOH
#define DNS_PREAMBLE "\x00\x00\x01\x00\x00\x01\x00\x00\x00\x00\x00\x00"
#define LABEL_TEST "\x04\x74\x65\x73\x74"
#define LABEL_HOST "\x04\x68\x6f\x73\x74"
@ -283,7 +283,7 @@ UNITTEST_START
}
UNITTEST_STOP
#else /* USE_NGHTTP2 */
#else /* CURL_DISABLE_DOH */
UNITTEST_START
{
return 1; /* nothing to do, just fail */

View File

@ -34,6 +34,8 @@ static void unit_stop(void)
/* done before shutting down and exiting */
}
#ifndef CURL_DISABLE_DOH
UNITTEST_START
/*
@ -175,3 +177,13 @@ do {
fail_unless(olen == olen1, "bad buffer length");
} while(0);
UNITTEST_STOP
#else /* CURL_DISABLE_DOH */
UNITTEST_START
{
return 1; /* nothing to do, just fail */
}
UNITTEST_STOP
#endif