sniper Mon Dec 9 06:50:15 2002 EDT
Modified files:
/php4/ext/standard dns.c
Log:
T_AAAA is not always available.
Index: php4/ext/standard/dns.c
diff -u php4/ext/standard/dns.c:1.49 php4/ext/standard/dns.c:1.50
--- php4/ext/standard/dns.c:1.49 Sun Dec 8 04:54:30 2002
+++ php4/ext/standard/dns.c Mon Dec 9 06:50:15 2002
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dns.c,v 1.49 2002/12/08 09:54:30 moriyoshi Exp $ */
+/* $Id: dns.c,v 1.50 2002/12/09 11:50:15 sniper Exp $ */
/* {{{ includes */
#include "php.h"
@@ -241,7 +241,9 @@
else if (!strcasecmp("ANY", Z_STRVAL_PP(arg2))) type = T_ANY;
else if (!strcasecmp("SOA", Z_STRVAL_PP(arg2))) type = T_SOA;
else if (!strcasecmp("CNAME", Z_STRVAL_PP(arg2))) type =
T_CNAME;
+#ifdef T_AAAA
else if (!strcasecmp("AAAA", Z_STRVAL_PP(arg2))) type =
T_AAAA;
+#endif
else {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Type '%s'
not supported", Z_STRVAL_PP(arg2));
RETURN_FALSE;
@@ -420,6 +422,8 @@
GETLONG(n, cp);
add_assoc_long(*subarray, "minimum-ttl", n);
break;
+
+#ifdef T_AAAA
case T_AAAA:
tp = name;
for(i=0; i < 8; i++) {
@@ -444,6 +448,8 @@
add_assoc_string(*subarray, "type", "AAAA", 1);
add_assoc_string(*subarray, "ipv6", name, 1);
break;
+#endif
+
default:
cp += dlen;
}
@@ -542,9 +548,11 @@
case 7:
type_to_fetch = type_param&PHP_DNS_TXT ? T_TXT : 0;
break;
+#ifdef T_AAAA
case 8:
type_to_fetch = type_param&PHP_DNS_AAAA ? T_AAAA : 0;
break;
+#endif
case 9:
store_results = 0;
continue;
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php