fixed upload for hosts

This commit is contained in:
Roland Gruber 2004-11-01 11:49:43 +00:00
parent 87dc904627
commit 88499fee73
1 changed files with 11 additions and 4 deletions

View File

@ -1034,11 +1034,18 @@ class posixAccount extends baseModule {
// TODO autoGID
$partialAccounts[$i]['uidNumber'] = 42;
}
elseif (get_preg($rawAccounts[$i][$ids['posixAccount_uid']], 'digit') &&
elseif (get_preg($rawAccounts[$i][$ids['posixAccount_uid']], 'digit')) {
if (($this->get_scope() == 'user') &&
($rawAccounts[$i][$ids['posixAccount_uid']] > $this->moduleSettings['posixAccount_minUID'][0]) &&
($rawAccounts[$i][$ids['posixAccount_uid']] < $this->moduleSettings['posixAccount_maxUID'][0])) {
$partialAccounts[$i]['uidNumber'] = $rawAccounts[$i][$ids['posixAccount_uid']];
}
elseif (($this->get_scope() == 'host') &&
($rawAccounts[$i][$ids['posixAccount_uid']] > $this->moduleSettings['posixAccount_minMachine'][0]) &&
($rawAccounts[$i][$ids['posixAccount_uid']] < $this->moduleSettings['posixAccount_maxMachine'][0])) {
$partialAccounts[$i]['uidNumber'] = $rawAccounts[$i][$ids['posixAccount_uid']];
}
}
else {
$errMsg = $this->messages['uidNumber'][4];
array_push($errMsg, array($i));