Home GnuPG
Diffusion GnuPG e03a4a94bb67

dirmngr: Do not use MAXDNAME.
e03a4a94bb67Unpublished

Unpublished Commit · Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

dirmngr: Do not use MAXDNAME.

* dirmngr/dns-stuff.c (getsrv): Replace MAXDNAME.
* dirmngr/dns-stuff.h (MAXDNAME): Remove.
(struct srventry): Use a fixed value instead of MAXDNAME.
* dirmngr/http.c (connect_server): Use DIMof instead of MAXDNAME.
Malloc a helper array.

Depending on the order of included headers it might be that we allocate
the array with a different size than what we test against in another
module. To make it more robust we use the actual known size of
checking.

A better would be to use a linked list and avoid these large arrays.

  • Signed-off-by: Werner Koch <wk@gnupg.org>

Details

Provenance
wernerAuthored on Oct 22 2015, 9:52 AM
Parents
rG41bb01ae792a: Move SRV RR code from common/ to dirmngr/.
Branches
Unknown
Tags
Unknown

Event Timeline

Werner Koch <wk@gnupg.org> committed rGe03a4a94bb67: dirmngr: Do not use MAXDNAME. (authored by Werner Koch <wk@gnupg.org>).Oct 22 2015, 9:52 AM