1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00

ext/standard: gethostbyaddr/gethostbyname using *NEW_STR flavor. (#18502)

This commit is contained in:
David CARLIER
2025-05-05 13:58:15 +01:00
committed by GitHub
parent c91c6545fe
commit 7855c52e81

View File

@@ -163,7 +163,7 @@ PHP_FUNCTION(gethostbyaddr)
#endif
RETVAL_FALSE;
} else {
RETVAL_STR(hostname);
RETVAL_NEW_STR(hostname);
}
}
/* }}} */
@@ -236,7 +236,7 @@ PHP_FUNCTION(gethostbyname)
php_error_docref(NULL, E_WARNING, "Host name to ip failed %s", hostname);
RETURN_STRINGL(hostname, hostname_len);
} else {
RETURN_STR(ipaddr);
RETURN_NEW_STR(ipaddr);
}
}
/* }}} */