diff options
Diffstat (limited to 'ext/standard/dns.c')
-rw-r--r-- | ext/standard/dns.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/standard/dns.c b/ext/standard/dns.c index 604e390ea3..ad085376b1 100644 --- a/ext/standard/dns.c +++ b/ext/standard/dns.c @@ -323,12 +323,12 @@ typedef union { #if defined(__GLIBC__) && !defined(HAVE_DEPRECATED_DNS_FUNCS) #define php_dns_free_res(__res__) _php_dns_free_res(__res__) -static void _php_dns_free_res(struct __res_state res) { /* {{{ */ +static void _php_dns_free_res(struct __res_state *res) { /* {{{ */ int ns; for (ns = 0; ns < MAXNS; ns++) { - if (res._u._ext.nsaddrs[ns] != NULL) { - free (res._u._ext.nsaddrs[ns]); - res._u._ext.nsaddrs[ns] = NULL; + if (res->_u._ext.nsaddrs[ns] != NULL) { + free (res->_u._ext.nsaddrs[ns]); + res->_u._ext.nsaddrs[ns] = NULL; } } } /* }}} */ |