]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Minimal fix to make primeHints threadsafe
authorChris Hofstaedtler <chris.hofstaedtler@deduktiva.com>
Fri, 19 Jan 2018 18:54:44 +0000 (19:54 +0100)
committerPieter Lexis <pieter.lexis@powerdns.com>
Mon, 22 Jan 2018 09:06:51 +0000 (10:06 +0100)
(cherry picked from commit e863a05ab7566450710f8cdc2c08750f00bcde33)

pdns/reczones.cc

index b0ac82748f09bc955afce0e1fe1cba32c544fe1a..afaf3575e9eb36f830d7b0ec3e6e8c2d944844cc 100644 (file)
@@ -53,7 +53,7 @@ void primeHints(void)
     arr.d_ttl=aaaarr.d_ttl=nsrr.d_ttl=time(0)+3600000;
     
     for(char c='a';c<='m';++c) {
-      static char templ[40];
+      char templ[40];
       strncpy(templ,"a.root-servers.net.", sizeof(templ) - 1);
       templ[sizeof(templ)-1] = '\0';
       *templ=c;