@@ -153,10 +153,10 @@ PHP_FUNCTION(gethostname)
153
153
PHP_FUNCTION (gethostbyaddr )
154
154
{
155
155
char * addr ;
156
- int addr_len ;
156
+ zend_str_size_int addr_len ;
157
157
char * hostname ;
158
158
159
- if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "s " , & addr , & addr_len ) == FAILURE ) {
159
+ if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "S " , & addr , & addr_len ) == FAILURE ) {
160
160
return ;
161
161
}
162
162
@@ -215,10 +215,10 @@ static char *php_gethostbyaddr(char *ip)
215
215
PHP_FUNCTION (gethostbyname )
216
216
{
217
217
char * hostname ;
218
- int hostname_len ;
218
+ zend_str_size_int hostname_len ;
219
219
char * addr ;
220
220
221
- if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "s " , & hostname , & hostname_len ) == FAILURE ) {
221
+ if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "S " , & hostname , & hostname_len ) == FAILURE ) {
222
222
return ;
223
223
}
224
224
@@ -233,12 +233,12 @@ PHP_FUNCTION(gethostbyname)
233
233
PHP_FUNCTION (gethostbynamel )
234
234
{
235
235
char * hostname ;
236
- int hostname_len ;
236
+ zend_str_size_int hostname_len ;
237
237
struct hostent * hp ;
238
238
struct in_addr in ;
239
239
int i ;
240
240
241
- if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "s " , & hostname , & hostname_len ) == FAILURE ) {
241
+ if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "S " , & hostname , & hostname_len ) == FAILURE ) {
242
242
return ;
243
243
}
244
244
@@ -346,7 +346,7 @@ PHP_FUNCTION(dns_check_record)
346
346
#endif
347
347
u_char ans [MAXPACKET ];
348
348
char * hostname , * rectype = NULL ;
349
- int hostname_len , rectype_len = 0 ;
349
+ zend_str_size_int hostname_len , rectype_len = 0 ;
350
350
int type = T_MX , i ;
351
351
#if defined(HAVE_DNS_SEARCH )
352
352
struct sockaddr_storage from ;
@@ -357,7 +357,7 @@ PHP_FUNCTION(dns_check_record)
357
357
struct __res_state * handle = & state ;
358
358
#endif
359
359
360
- if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "s|s " , & hostname , & hostname_len , & rectype , & rectype_len ) == FAILURE ) {
360
+ if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "S|S " , & hostname , & hostname_len , & rectype , & rectype_len ) == FAILURE ) {
361
361
return ;
362
362
}
363
363
@@ -714,7 +714,7 @@ static u_char *php_parserr(u_char *cp, querybuf *answer, int type_to_fetch, int
714
714
PHP_FUNCTION (dns_get_record )
715
715
{
716
716
char * hostname ;
717
- int hostname_len ;
717
+ zend_str_size_int hostname_len ;
718
718
long type_param = PHP_DNS_ANY ;
719
719
zval * authns = NULL , * addtl = NULL ;
720
720
int type_to_fetch ;
@@ -733,7 +733,7 @@ PHP_FUNCTION(dns_get_record)
733
733
int type , first_query = 1 , store_results = 1 ;
734
734
zend_bool raw = 0 ;
735
735
736
- if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "s |lz!z!b" ,
736
+ if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "S |lz!z!b" ,
737
737
& hostname , & hostname_len , & type_param , & authns , & addtl , & raw ) == FAILURE ) {
738
738
return ;
739
739
}
@@ -926,7 +926,7 @@ PHP_FUNCTION(dns_get_record)
926
926
PHP_FUNCTION (dns_get_mx )
927
927
{
928
928
char * hostname ;
929
- int hostname_len ;
929
+ zend_str_size_int hostname_len ;
930
930
zval * mx_list , * weight_list = NULL ;
931
931
int count , qdc ;
932
932
u_short type , weight ;
@@ -944,7 +944,7 @@ PHP_FUNCTION(dns_get_mx)
944
944
struct __res_state * handle = & state ;
945
945
#endif
946
946
947
- if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "sz |z" , & hostname , & hostname_len , & mx_list , & weight_list ) == FAILURE ) {
947
+ if (zend_parse_parameters (ZEND_NUM_ARGS () TSRMLS_CC , "Sz |z" , & hostname , & hostname_len , & mx_list , & weight_list ) == FAILURE ) {
948
948
return ;
949
949
}
950
950
0 commit comments