Skip to content

Commit 0123c99

Browse files
committed
Fix bug55509.phpt skipif on FreeBSD
1 parent 79c9028 commit 0123c99

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Zend/tests/bug55509.phpt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,13 @@ elseif (PHP_OS == 'FreeBSD') {
3131
$lines = explode("\n",`sysctl -a`);
3232
$infos = array();
3333
foreach ($lines as $line) {
34-
if(!$line){
34+
if (!$line){
3535
continue;
3636
}
3737
$tmp = explode(":", $line);
38+
if (count($tmp) < 2) {
39+
continue;
40+
}
3841
$index = strtolower($tmp[0]);
3942
$value = trim($tmp[1], " ");
4043
$infos[$index] = $value;

0 commit comments

Comments
 (0)