From e411c7e22f28df7f746b48b8f3afa4d76921da84 Mon Sep 17 00:00:00 2001 From: psc Date: Mon, 13 Jul 2009 14:07:01 +0000 Subject: [PATCH] - When checking if a share is in use by other objects, also check if it is in use by object groups. - Also check for used shares if removing the share only (and not the whole service or server) git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.6-lhm@13926 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../admin/systems/services/shares/class_goShareServer.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/trunk/gosa-plugins/goto/admin/systems/services/shares/class_goShareServer.inc b/trunk/gosa-plugins/goto/admin/systems/services/shares/class_goShareServer.inc index 7d7b05d9a..f4ad3050f 100644 --- a/trunk/gosa-plugins/goto/admin/systems/services/shares/class_goShareServer.inc +++ b/trunk/gosa-plugins/goto/admin/systems/services/shares/class_goShareServer.inc @@ -221,7 +221,7 @@ class goShareServer extends goService{ $ldap = $this->config->get_ldap_link(); $ldap->cd($this->config->current['BASE']); $cn = $ldap->getCn($this->dn); - $ldap->search("(&(|(objectClass=posixGroup)(objectClass=posixAccount))(gotoShare=$cn|*))", array("dn")); + $ldap->search("(&(|(objectClass=posixGroup)(objectClass=posixAccount)(objectClass=gosaGroupOfNames))(gotoShare=$cn|*))", array("dn")); if($ldap->count()){ /* Number of entries shown in warning */ @@ -248,7 +248,7 @@ class goShareServer extends goService{ /* Check if the share is used by someone */ $ldap = $this->config->get_ldap_link(); $ldap->cd($this->config->current['BASE']); - $ldap->search("(|(gotoProfileServer=*|$id)(gotoShare=*|$id|*||*))", array("cn")); + $ldap->search("(|(gotoProfileServer=*|$id)(gotoShare=*|$id|*))", array("cn")); if ($ldap->count() != 0){ while ($attrs= $ldap->fetch()){ $obj[$ldap->getDN()]= $attrs['cn'][0]; -- 2.30.2