From: Remi Gacogne Date: Wed, 8 Nov 2017 11:23:12 +0000 (+0100) Subject: rec: Don't crash when asked to run with zero threads X-Git-Tag: auth-4.1.0-rc3~10^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1c4f2e1bd44482c2ef38012a76a255eee130cd03;p=pdns rec: Don't crash when asked to run with zero threads --- diff --git a/pdns/pdns_recursor.cc b/pdns/pdns_recursor.cc index e987037e0..324c51468 100644 --- a/pdns/pdns_recursor.cc +++ b/pdns/pdns_recursor.cc @@ -2986,6 +2986,11 @@ static int serviceMain(int argc, char*argv[]) g_lowercaseOutgoing = ::arg().mustDo("lowercase-outgoing"); g_numWorkerThreads = ::arg().asNum("threads"); + if (g_numWorkerThreads < 1) { + L<