Skip to content

Commit ca58557

Browse files
committed
Fix indentation
1 parent 1dc13d2 commit ca58557

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

ext/standard/basic_functions.c

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -598,18 +598,18 @@ PHP_FUNCTION(ip2long)
598598
if (addr_len == 0 || inet_pton(AF_INET, addr, &ip) != 1) {
599599
RETURN_FALSE;
600600
}
601-
#ifdef _AIX
602-
/*
603-
AIX accepts IP strings with excedentary 0 (192.168.042.42 will be treated as
604-
192.168.42.42), while Linux don't.
605-
For consistency, we convert back the IP to a string and check if it is equal to
606-
the original string. If not, the IP should be considered invalid.
607-
*/
608-
char str[INET_ADDRSTRLEN];
609-
if (strcmp(addr, inet_ntop(AF_INET, &ip, str, sizeof(str))) != 0) {
610-
RETURN_FALSE;
611-
}
612-
#endif
601+
#ifdef _AIX
602+
/*
603+
AIX accepts IP strings with excedentary 0 (192.168.042.42 will be treated as
604+
192.168.42.42), while Linux don't.
605+
For consistency, we convert back the IP to a string and check if it is equal to
606+
the original string. If not, the IP should be considered invalid.
607+
*/
608+
char str[INET_ADDRSTRLEN];
609+
if (strcmp(addr, inet_ntop(AF_INET, &ip, str, sizeof(str))) != 0) {
610+
RETURN_FALSE;
611+
}
612+
#endif
613613
RETURN_LONG(ntohl(ip.s_addr));
614614
}
615615
/* }}} */

0 commit comments

Comments
 (0)