cleanup - fix some php notices, closes https://github.com/opnsense/core/issues/8125

This commit is contained in:
Ad Schellevis 2024-12-11 16:15:31 +01:00
parent be8841d9af
commit 002b450c40
2 changed files with 6 additions and 2 deletions

View File

@ -40,7 +40,8 @@ function &lookup_ca($refid)
}
}
return false;
$false = false;
return $false;
}
function &lookup_ca_by_subject($subject)
@ -94,6 +95,9 @@ function ca_chain_array(&$cert)
if ($cert['caref']) {
$chain = array();
$crt = lookup_ca($cert['caref']);
if (!$crt) {
return false;
}
$chain[] = $crt;
while ($crt) {
$caref = isset($crt['caref']) ? $crt['caref'] : false;

View File

@ -284,7 +284,7 @@ abstract class Base
$timeleft = $expected_time - ((microtime(true) - $tstart) * 1000000);
if (!$result && $timeleft > 0) {
usleep($timeleft);
usleep((int)$timeleft);
}
return $result;