1 .\" (C) 2002 Ian Gulliver
2 .TH firedns_resolvemxalist 3 2004-02-12
4 firedns_resolvemxalist \- Resolve a list of MX records of a hostname and their corresponding A records
6 .B #include <firedns.h>
10 .BI "struct firedns_mxlist *firedns_resolvemxalist(const char * const " "name" ")"
12 firedns_resolvemxalist() attempts to resolve a list of MX records
15 If it fails, it treats the host as having a priority 0 MX record,
16 and attempts to resolve a list of A and AAAA records for the hostname. If the MX record lookup
17 succeeds, it looks up the list of A and AAAA records for each MX record in parallel. It also
18 checks for RFC-violating CNAMEs for each MX record.
20 Returns a pointer to an internal static
21 .IR "struct firedns_mxlist *".
22 This structure is the first of a linked list. It contains:
28 struct firedns_ip4list *ip4list;
30 struct firedns_ip6list *ip6list;
32 unsigned int protocol;
33 .RI ( FIREDNS_MX_SMTP " or " FIREDNS_MX_QMTP )
35 unsigned int priority;
37 struct firedns_mxlist *next;
39 This function returns NULL on error.
41 Any result return by this function should be freed with
42 .IR firedns_free_mxalist (3).
44 Ian Gulliver <ian@penguinhosting.net>
48 .BR firedns_free_mxalist (3)