summaryrefslogtreecommitdiff
path: root/src/libs6dns/s6dns_message_get_domain.c
blob: 5632af99617dcd9a63e3d9e1b579e063fdf14779 (plain)
1
2
3
4
5
6
7
8
9
10
/* ISC license. */

#include <s6-dns/s6dns-domain.h>
#include <s6-dns/s6dns-message.h>

int s6dns_message_get_domain (s6dns_domain_t *d, char const *packet, unsigned int packetlen, unsigned int *pos)
{
  return s6dns_message_get_domain_nodecode(d->s, 255, packet, packetlen, pos)
      && s6dns_domain_decode(d) ;
}