PHP 7.2 compatibility

This commit is contained in:
Roland Gruber 2018-04-30 19:29:31 +02:00
parent a9ac81352e
commit 632d3a26bd
1 changed files with 2 additions and 2 deletions

View File

@ -2240,9 +2240,9 @@ class sambaSamAccount extends baseModule implements passwordService {
// passwords ( = host name) // passwords ( = host name)
$partialAccounts[$i]['sambaPwdLastSet'] = time(); $partialAccounts[$i]['sambaPwdLastSet'] = time();
if (isset($this->moduleSettings['sambaSamAccount_lmHash'][0]) && ($this->moduleSettings['sambaSamAccount_lmHash'][0] == 'no')) { if (isset($this->moduleSettings['sambaSamAccount_lmHash'][0]) && ($this->moduleSettings['sambaSamAccount_lmHash'][0] == 'no')) {
$partialAccounts[$i]['sambaLMPassword'] = lmPassword(substr($partialAccounts[$i]['uid'], 0, sizeof($partialAccounts[$i]['uid']) - 1)); $partialAccounts[$i]['sambaLMPassword'] = lmPassword(substr($partialAccounts[$i]['uid'], 0, strlen($partialAccounts[$i]['uid']) - 1));
} }
$partialAccounts[$i]['sambaNTPassword'] = ntPassword(substr($partialAccounts[$i]['uid'], 0, sizeof($partialAccounts[$i]['uid']) - 1)); $partialAccounts[$i]['sambaNTPassword'] = ntPassword(substr($partialAccounts[$i]['uid'], 0, strlen($partialAccounts[$i]['uid']) - 1));
// flags // flags
$partialAccounts[$i]['sambaAcctFlags'] = "[W ]"; $partialAccounts[$i]['sambaAcctFlags'] = "[W ]";
} }