From: Peter van Dijk Date: Wed, 13 May 2015 13:27:56 +0000 (+0200) Subject: s/getLabel/getName/ X-Git-Tag: dnsdist-1.0.0-alpha1~248^2~58^2~21^2~5^2~83 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8ad443eac3700637b0fa7c3e54e6d72222b34290;p=thirdparty%2Fpdns.git s/getLabel/getName/ --- diff --git a/pdns/dnsparser.cc b/pdns/dnsparser.cc index fc04d9bf65..6a8c159268 100644 --- a/pdns/dnsparser.cc +++ b/pdns/dnsparser.cc @@ -246,7 +246,7 @@ void MOADNSParser::init(const char *packet, unsigned int len) d_qtype = d_qclass = 0; // sometimes replies come in with no question, don't present garbage then for(n=0;n < d_header.qdcount; ++n) { - d_qname=pr.getLabel(); + d_qname=pr.getName(); d_qtype=pr.get16BitInt(); d_qclass=pr.get16BitInt(); } @@ -266,7 +266,7 @@ void MOADNSParser::init(const char *packet, unsigned int len) unsigned int recordStartPos=pr.d_pos; - string label=pr.getLabel(); + string label=pr.getName(); pr.getDnsrecordheader(ah); dr.d_ttl=ah.d_ttl; @@ -400,7 +400,7 @@ uint8_t PacketReader::get8BitInt() return d_content.at(d_pos++); } -string PacketReader::getLabel() +string PacketReader::getName() { unsigned int consumed; vector content(d_content); @@ -497,7 +497,7 @@ void PacketReader::xfrHexBlob(string& blob, bool keepReading) string simpleCompress(const string& elabel, const string& root) { string label=elabel; - // FIXME: this relies on the semi-canonical escaped output from getLabel + // FIXME: this relies on the semi-canonical escaped output from getName if(strchr(label.c_str(), '\\')) { boost::replace_all(label, "\\.", "."); boost::replace_all(label, "\\032", " "); diff --git a/pdns/dnsparser.hh b/pdns/dnsparser.hh index 4a09c75f09..4e57b0810f 100644 --- a/pdns/dnsparser.hh +++ b/pdns/dnsparser.hh @@ -121,7 +121,7 @@ public: void xfrName(string &label, bool compress=false) { - label=getLabel(); + label=getName(); } void xfrText(string &text, bool multi=false) @@ -140,7 +140,7 @@ public: void copyRecord(vector& dest, uint16_t len); void copyRecord(unsigned char* dest, uint16_t len); - string getLabel(); + string getName(); string getText(bool multi); uint16_t d_pos; diff --git a/pdns/dnswriter.cc b/pdns/dnswriter.cc index 5286439a25..81efaa14a3 100644 --- a/pdns/dnswriter.cc +++ b/pdns/dnswriter.cc @@ -249,7 +249,7 @@ void DNSPacketWriter::xfrName(const string& Label, bool compress) if(unescaped) { string part(label.c_str() + i -> first, i->second - i->first); - // FIXME: this relies on the semi-canonical escaped output from getLabel + // FIXME: this relies on the semi-canonical escaped output from getName boost::replace_all(part, "\\.", "."); boost::replace_all(part, "\\032", " "); boost::replace_all(part, "\\\\", "\\");