From: Willem Toorop Date: Mon, 26 Jan 2015 13:38:12 +0000 (+0100) Subject: bugfix #633: ldns_pkt_clone const parameter X-Git-Tag: release-1.7.0-rc1~106 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=726628ba281b6e0cb619e5a9eb303e1ecc9a2011;p=thirdparty%2Fldns.git bugfix #633: ldns_pkt_clone const parameter Thanks Jakop Petsovits --- diff --git a/Changelog b/Changelog index e07d039e..b3201dfa 100644 --- a/Changelog +++ b/Changelog @@ -46,6 +46,8 @@ TBD in sync with the usage text, and don't alter the ldns_resolver passed to ldns_update_soa_zone_mname(). Created a ldns_resolver_clone() function in the process. Thanks Nicholas Riley. + * bugfix #633: ldns_pkt_clone() parameter isn't const. + Thanks Jakop Petsovits 1.6.17 2014-01-10 * Fix ldns_dnssec_zone_new_frm_fp_l to allow the last parsed line of a diff --git a/ldns/packet.h b/ldns/packet.h index 2732e94f..e66aa34e 100644 --- a/ldns/packet.h +++ b/ldns/packet.h @@ -811,7 +811,7 @@ ldns_pkt *ldns_pkt_ixfr_request_new(ldns_rdf *rr_name, ldns_rr_class rr_class, u * \param[in] pkt the packet to clone * \return ldns_pkt* pointer to the new packet */ -ldns_pkt *ldns_pkt_clone(ldns_pkt *pkt); +ldns_pkt *ldns_pkt_clone(const ldns_pkt *pkt); /** * directly set the additional section diff --git a/packet.c b/packet.c index 3e26a6fe..62bfd079 100644 --- a/packet.c +++ b/packet.c @@ -1105,7 +1105,7 @@ ldns_pkt_reply_type(ldns_pkt *p) } ldns_pkt * -ldns_pkt_clone(ldns_pkt *pkt) +ldns_pkt_clone(const ldns_pkt *pkt) { ldns_pkt *new_pkt;