]> granicus.if.org Git - pdns/commitdiff
make it possible to generate ARecords from 32 bit integers directly
authorBert Hubert <bert.hubert@netherlabs.nl>
Sun, 24 Aug 2008 15:37:11 +0000 (15:37 +0000)
committerBert Hubert <bert.hubert@netherlabs.nl>
Sun, 24 Aug 2008 15:37:11 +0000 (15:37 +0000)
git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@1259 d19b8d6e-7fed-0310-83ef-9ca221ded41b

pdns/dnsrecords.cc
pdns/dnsrecords.hh

index 8c59a769000caa835796265ebabc23ef34f2dded..373eddbca22f76b760a141fa20caddebd1ad7b76 100644 (file)
 
 boilerplate_conv(A, ns_t_a, conv.xfrIP(d_ip));
 
+ARecordContent::ARecordContent(uint32_t ip) : DNSRecordContent(ns_t_a)
+{
+  d_ip = ip;
+}
+
 uint32_t ARecordContent::getIP() const
 {
   return d_ip;
index e8b2968bb143e0af9457db51a704d5e082a21fc0..96c0bb07e8ece4b3e551ee354be01ff85396f7b8 100644 (file)
@@ -54,6 +54,7 @@ private:
 class ARecordContent : public DNSRecordContent
 {
 public:
+  explicit ARecordContent(uint32_t ip);
   includeboilerplate(A);
   void doRecordCheck(const DNSRecord& dr);
   uint32_t getIP() const;