summaryrefslogtreecommitdiff
path: root/mail/postfix/patches
diff options
context:
space:
mode:
authoritojun <itojun>2002-07-17 22:34:45 +0000
committeritojun <itojun>2002-07-17 22:34:45 +0000
commitbc2ad7e69b58959a5441b66957af71f55c1b7d69 (patch)
treee25bc1cb02ae6a4966e41e0b07b0f3bb46bb4ac6 /mail/postfix/patches
parent2a91f1829d329bdb68908ec96ebd68d46952e4d3 (diff)
downloadpkgsrc-bc2ad7e69b58959a5441b66957af71f55c1b7d69.tar.gz
parse T_AAAA responses. patch sent to wietse.
Diffstat (limited to 'mail/postfix/patches')
-rw-r--r--mail/postfix/patches/patch-ah31
1 files changed, 31 insertions, 0 deletions
diff --git a/mail/postfix/patches/patch-ah b/mail/postfix/patches/patch-ah
new file mode 100644
index 00000000000..132cec76ded
--- /dev/null
+++ b/mail/postfix/patches/patch-ah
@@ -0,0 +1,31 @@
+$NetBSD: patch-ah,v 1.3 2002/07/17 22:34:46 itojun Exp $
+
+diff -u -r1.3 src/dns/dns_lookup.c
+--- src/dns/dns_lookup.c 2001/11/11 05:26:51 1.3
++++ src/dns/dns_lookup.c 2002/07/17 21:20:30
+@@ -132,6 +132,7 @@
+ } DNS_REPLY;
+
+ #define INET_ADDR_LEN 4 /* XXX */
++#define INET6_ADDR_LEN 16 /* XXX */
+
+ /* dns_query - query name server and pre-parse the reply */
+
+@@ -328,6 +329,17 @@
+ break;
+ case T_A:
+ if (fixed->length != INET_ADDR_LEN) {
++ msg_warn("extract_answer: bad address length: %d", fixed->length);
++ return (0);
++ }
++ if (fixed->length > sizeof(temp))
++ msg_panic("dns_get_rr: length %d > DNS_NAME_LEN",
++ fixed->length);
++ memcpy(temp, pos, fixed->length);
++ data_len = fixed->length;
++ break;
++ case T_AAAA:
++ if (fixed->length != INET6_ADDR_LEN) {
+ msg_warn("extract_answer: bad address length: %d", fixed->length);
+ return (0);
+ }