dns/client: refactor with const structs
@@ -330,7 +330,7 @@ static int reply_recv(struct dnsc *dnsc, struct mbuf *mb)
/* Cache negative answer with SOA minimum value (RFC 2308) */
if (!dq.hdr.nans && dq.hdr.nauth) {
- struct dnsrr *rr = list_ledata(list_head(&q->rrlv[1]));
+ const struct dnsrr *rr = list_ledata(list_head(&q->rrlv[1]));
if (!rr || rr->type != DNS_TYPE_SOA) {
mem_deref(q);
@@ -728,7 +728,7 @@ static void hdl_tmr_cache(void *arg)
static bool query_cache_handler(struct dns_query *q)
{
struct dnsquery dq;
- struct dns_query *qc = NULL;
+ const struct dns_query *qc = NULL;
struct le *le;
dq.hdr = q->hdr;
