add upstream patch 3036 to fix ECDSA
[pkg-pdns/pdns.git] / debian / patches / supermaster-race-2575
1 --- a/pdns/packethandler.cc
2 +++ b/pdns/packethandler.cc
3 @@ -778,7 +778,13 @@
4      L<<Logger::Error<<"Unable to find backend willing to host "<<p->qdomain<<" for potential supermaster "<<p->getRemote()<<endl;
5      return RCode::Refused;
6    }
7 -  db->createSlaveDomain(p->getRemote(),p->qdomain,account);
8 +  try {
9 +    db->createSlaveDomain(p->getRemote(),p->qdomain,account);
10 +  }
11 +  catch(AhuException& ae) {
12 +    L<<Logger::Error<<"Database error trying to create "<<p->qdomain<<" for potential supermaster "<<p->getRemote()<<": "<<ae.reason<<endl;
13 +    return RCode::ServFail;
14 +  }
15    Communicator.addSuckRequest(p->qdomain, p->getRemote());  
16    L<<Logger::Warning<<"Created new slave zone '"<<p->qdomain<<"' from supermaster "<<p->getRemote()<<", queued axfr"<<endl;
17    return RCode::NoError;