diff options
author | Daniel Stenberg <daniel@haxx.se> | 2019-05-05 17:08:21 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2019-05-13 08:17:09 +0200 |
commit | ae4adae954c958f1e3b45e6759fec6095137b23c (patch) | |
tree | a1c13daf53adb8019bfa4c51c9e69f8c910db94e /lib/doh.h | |
parent | 52dfab65d6822d1281bb62ebc5c46cd2b7501487 (diff) | |
download | curl-ae4adae954c958f1e3b45e6759fec6095137b23c.tar.gz |
doh: CURL_DISABLE_DOH
Diffstat (limited to 'lib/doh.h')
-rw-r--r-- | lib/doh.h | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -7,7 +7,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 2018, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 2018 - 2019, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -25,6 +25,8 @@ #include "urldata.h" #include "curl_addrinfo.h" +#ifndef CURL_DISABLE_DOH + /* * Curl_doh() resolve a name using DoH (DNS-over-HTTPS). It resolves a name * and returns a 'Curl_addrinfo *' with the address information. @@ -102,4 +104,10 @@ DOHcode doh_decode(unsigned char *doh, struct dohentry *d); void de_cleanup(struct dohentry *d); #endif + +#else /* if DOH is disabled */ +#define Curl_doh(a,b,c,d) NULL +#define Curl_doh_is_resolved(x,y) CURLE_COULDNT_RESOLVE_HOST +#endif + #endif /* HEADER_CURL_DOH_H */ |