]> granicus.if.org Git - pdns/commitdiff
Use reinterpret_cast consistently for dnsheader
authorAki Tuomi <cmouse@cmouse.fi>
Sun, 18 Oct 2015 17:58:25 +0000 (20:58 +0300)
committerAki Tuomi <cmouse@desteem.org>
Mon, 26 Oct 2015 10:28:03 +0000 (12:28 +0200)
pdns/dnswriter.cc

index eda9b87fce80401d53e3803a3b42d0b91d47a86f..9205108f403e32ac7320ce8da253709e3b8e236b 100644 (file)
@@ -60,7 +60,7 @@ DNSPacketWriter::DNSPacketWriter(vector<uint8_t>& content, const DNSName& qname,
 
 dnsheader* DNSPacketWriter::getHeader()
 {
-  return (dnsheader*)&*d_content.begin();
+  return reinterpret_cast<dnsheader*>(&*d_content.begin());
 }
 
 void DNSPacketWriter::startRecord(const DNSName& name, uint16_t qtype, uint32_t ttl, uint16_t qclass, DNSResourceRecord::Place place, bool compress)