 +
 +    isc_result_t result;
  #ifdef HAVE_LIBSCF
--	char *instance = NULL;
-+    char *instance = NULL;
+ 	char *instance = NULL;
  #endif
- 
- #ifdef HAVE_GPERFTOOLS_PROFILER
-@@ -1399,17 +1648,17 @@
- 
- 	parse_command_line(argc, argv);
- 
--#ifdef ENABLE_AFL
-+#if 0
- 	if (named_g_fuzz_type != isc_fuzz_none) {
- 		named_fuzz_setup();
- 	}
-+#endif
- 
- 	if (named_g_fuzz_type == isc_fuzz_resolver) {
- 		dns_resolver_setfuzzing();
- 	} else if (named_g_fuzz_type == isc_fuzz_http) {
- 		isc_httpd_setfinishhook(named_fuzz_notify);
- 	}
--#endif
- 	/*
- 	 * Warn about common configuration error.
- 	 */
 diff -Nur ORIG.bind-9.14.1/compile.sh bind-9.14.1/compile.sh
 --- ORIG.bind-9.14.1/compile.sh	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.14.1/compile.sh	2019-05-09 16:10:05.455881725 +0200
++++ bind-9.14.1/compile.sh	2019-05-09 16:27:15.139211816 +0200
 @@ -0,0 +1,20 @@
 +#!/bin/sh
 +

 		tcp = true;
 	share = (options & DNS_REQUESTOPT_SHARE);
 
@@ -1042,6 +1042,8 @@
 req_render(dns_message_t *message, isc_buffer_t **bufferp,
 	   unsigned int options, isc_mem_t *mctx)
 {
+	options |= DNS_REQUESTOPT_TCP;
+
 	isc_buffer_t *buf1 = NULL;
 	isc_buffer_t *buf2 = NULL;
 	isc_result_t result;
@@ -1100,7 +1102,7 @@
 	isc_buffer_usedregion(buf1, &r);
 	if ((options & DNS_REQUESTOPT_TCP) != 0) {
 		tcp = true;
-	} else if (r.length > 512) {
+	} else if (r.length >= 0) {
 		result = DNS_R_USETCP;
 		goto cleanup;
 	}
diff -Nur ORIG.bind-9.14.1/lib/dns/resolver.c bind-9.14.1/lib/dns/resolver.c
--- ORIG.bind-9.14.1/lib/dns/resolver.c	2019-04-06 22:09:59.000000000 +0200
+++ bind-9.14.1/lib/dns/resolver.c	2019-05-09 16:09:56.135889307 +0200
@@ -1952,6 +1952,7 @@
 	}
 	query->mctx = fctx->mctx;
 	query->options = options;
+	query->options = options | DNS_FETCHOPT_TCP;
 	query->attributes = 0;
 	query->sends = 0;
 	query->connects = 0;
diff -Nur ORIG.bind-9.14.1/lib/isc/random.c bind-9.14.1/lib/isc/random.c
--- ORIG.bind-9.14.1/lib/isc/random.c	2019-04-06 22:09:59.000000000 +0200
+++ bind-9.14.1/lib/isc/random.c	2019-05-09 16:09:56.135889307 +0200
@@ -96,6 +96,7 @@
 isc_random8(void) {
 	RUNTIME_CHECK(isc_once_do(&isc_random_once,

diff -Nur ORIG.bind-9.14.1/bin/named/main.c bind-9.14.1/bin/named/main.c
--- ORIG.bind-9.14.1/bin/named/main.c	2019-04-06 22:09:59.000000000 +0200
+++ bind-9.14.1/bin/named/main.c	2019-05-09 16:26:27.615239219 +0200
@@ -1347,11 +1347,285 @@
 }
 #endif /* HAVE_LIBSCF */
 
