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

#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)
{
  int r = s6dns_message_get_string_internal(d->s, 255, packet, packetlen, pos) ;
  if (r < 0) return 0 ;
  d->len = r ;
  return 1 ;
}