chiark / gitweb /
shared: dns-name - introduce dns_label_unescape_suffix()
authorTom Gundersen <teg@jklm.no>
Mon, 20 Jul 2015 14:01:03 +0000 (16:01 +0200)
committerSven Eden <yamakuzure@gmx.net>
Tue, 14 Mar 2017 09:07:02 +0000 (10:07 +0100)
commit919d0fd3c8394b0988c0b4f81c081a20f25a8e87
treeb9a34fb8176be29b7f4e8c42f71b1b0e1c75440a
parentb22f231c1eb04e77ca79df676d5989ae1061fbaf
shared: dns-name - introduce dns_label_unescape_suffix()

Intended to be called repeatedly, and returns then successive unescaped labels
from the most to the least significant (left to right).

This is slightly inefficient as it scans the string three times (two would be
sufficient): once to find the end of the string, once to find the beginning
of each label and lastly once to do the actual unescaping. The latter two
could be done in one go, but that seemed unnecessarily convoluted.
src/shared/dns-domain.c
src/shared/dns-domain.h
src/test/test-dns-domain.c