chiark / gitweb /
adns_str* etc.: Return NULL rather than crashing, and docs
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Mon, 25 May 2020 11:55:33 +0000 (12:55 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 11 Jun 2020 15:13:02 +0000 (16:13 +0100)
commit2b44fb38172ff0d64d1d5d907e3322d5e1a6a8ca
tree8be5ef35479553063fbdff3594eaca3c86c96cc5
parent66281621c79487987b33e65c216c5c71bf9289bf
adns_str* etc.: Return NULL rather than crashing, and docs

Previously, calling these functions with arbitrary values would cause
them to do a struct member lookup on a null pointer.  Now they return
the pointer instead.

Also, some users have been confused by the docs, and have passsed, for
example, adns_s_max_misconfig.  This is also not permitted.  Clarify
that only values actually returned by adns are allowed.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
src/adns.h
src/general.c