summaryrefslogtreecommitdiff
path: root/src/libs6dns/s6dns_message_get_string.c
blob: 706da391d12271a93e27f38abbb8bbff6389edba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
/* ISC license. */

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

int s6dns_message_get_string (s6dns_domain_t *d, char const *packet, unsigned int packetlen, unsigned int *pos)
{
  register int r = s6dns_message_get_string_internal(d->s, 255, packet, packetlen, pos) ;
  if (r < 0) return 0 ;
  d->len = r ;
  return 1 ;
}