Changeset 2540

Show
Ignore:
Timestamp:
03/28/12 18:08:07 (15 months ago)
Author:
peter
Message:

fix disappearance of SOA during incoming AXFR. Patch by Ruben d'Arco.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/pdns/pdns/resolver.cc

    r2506 r2540  
    440440  for(Resolver::res_t::const_iterator i= res.begin(); i!=res.end(); ++i) { 
    441441    if(i->qtype.getCode()==QType::SOA) { 
    442       removeItems.push_back(i-res.begin()); 
    443442      d_soacount++; 
    444     } 
    445   } 
    446  
    447   if (!removeItems.empty() && d_soacount > 1) { 
     443      if (d_soacount>1) 
     444        removeItems.push_back(i-res.begin()); 
     445    } 
     446  } 
     447 
     448 
     449  if (!removeItems.empty()) { 
    448450    BOOST_FOREACH(uint32_t i, removeItems) { 
    449451      res.erase(res.begin()+i);