summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2e9813a)
raw | patch | inline | side by side (parent: 2e9813a)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 9 Nov 2006 07:05:14 +0000 (07:05 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 9 Nov 2006 07:05:14 +0000 (07:05 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@5053 594d385d-05f5-0310-b6e9-bd551577e9d8
plugins/personal/posix/class_posixAccount.inc | patch | blob | history |
diff --git a/plugins/personal/posix/class_posixAccount.inc b/plugins/personal/posix/class_posixAccount.inc
index fca536fb9b3e2cf41e9c2c86383ae385b82851c1..9db5681170926940b3d9bb84fb67474cac4b2029 100644 (file)
del_lock ("uidnumber");
- /* Posix accounts have group interrelationship, take care about these here. */
- if ($this->force_ids == 0 && $this->primaryGroup == 0){
+ /* Posix accounts have group interrelationship,
+ take care about these here if this is a new user without forced gidNumber. */
+ if ($this->force_ids == 0 && $this->primaryGroup == 0 && !$this->initially_was_account){
$ldap->cd($this->config->current['BASE']);
$ldap->search("(&(objectClass=posixGroup)(gidNumber=".$this->gidNumber."))", array("cn"));
/* Create group if it doesn't exist */
if ($ldap->count() == 0){
$groupdn= preg_replace ('/^'.$this->config->current['DNMODE'].'=[^,]+,'.get_people_ou().'/i', 'cn='.$this->uid.','.get_groups_ou(), $this->dn);
-
$g= new group($this->config, $groupdn);
$g->cn= $this->uid;
$g->force_gid= 1;